<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic GMT YTD flag-- Load problem in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225788#M78054</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;As per my understanding if the date lies with in the year2date it returns true i.e -1 in your case but when you are comparing with respect to current day it is showing false i.e 0(Zero), i feel u need to mention one parameter called todayaDate in YEARTODATE FORMAT&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i.e&lt;/P&gt;&lt;P&gt;YEARTODATE( DATE [,Yearoffset [ , FirstMonth &lt;STRONG&gt;[ , TodayDate]&lt;/STRONG&gt; ] ])&lt;/P&gt;&lt;P&gt;what i mean is give the Date parameter which is the upper bound of the date i.e As shown below&lt;/P&gt;&lt;P&gt;Year2Date(INVOICE_DATE,0,4,Today()) * -1 &lt;B&gt;as&lt;/B&gt; FY_YTD_Flag&lt;/P&gt;&lt;P&gt;I tried few samples and it has given the following results&lt;/P&gt;&lt;P&gt;Year2Date( '2010-04-29' ,0,4, '2010-04-26' ) Returns Zero which is 0 i.e False&lt;/P&gt;&lt;P&gt;Year2Date( '2010-04-29' ,0,4, '2010-04-26' ) Returns -1 which is True&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try the above things hope this will reslve the prob;lem,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ajay&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 29 Apr 2010 07:21:03 GMT</pubDate>
    <dc:creator>spsrk_84</dc:creator>
    <dc:date>2010-04-29T07:21:03Z</dc:date>
    <item>
      <title>GMT YTD flag-- Load problem</title>
      <link>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225787#M78053</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Does anyone have any sugguestions on how I should handle timezone issues in my scirpt. Any help will be greatly appreciated. I have been struggling with this for sometime now.&lt;/P&gt;&lt;P&gt;Here is my YTD syntax:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;Year2Date(INVOICE_DATE,0,4) * -1 &lt;B&gt;as&lt;/B&gt; FY_YTD_Flag&lt;/P&gt;&lt;P&gt;My gauge uses :(Sum(SALESVALUE * FY_YTD_Flag))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is when job is executed from publisher at 7:10 edt it does not pickup invoices dated today's date example(4/27/10), but only picks up 4/26/10. On my calendar table YTD Flag is set to '1' through 4/26/10 and does not include 4/27/10. When I select YTD_FLG= 0 then 4/27/10 is included.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For example today job executed @ 7:10 am edt and completed @ 7:20am edt. YTD Flag was off. I manaully executed application again @ 7:56 am edt and job completed @ 8:06am edt..Flags were correct. 4/27/10 was included.&lt;/P&gt;&lt;P&gt;How is YTD determined based on system date and time or current day today() date and time?&lt;/P&gt;&lt;P&gt;What do I need to add to my script to prevent this from happening? Or, do I need to something on the Publisher trigger? I have to load this job before 8:00am edt and include all data upto current day.&lt;/P&gt;&lt;P&gt;Please help!!!!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 Apr 2010 16:05:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225787#M78053</guid>
      <dc:creator>karensmith</dc:creator>
      <dc:date>2010-04-27T16:05:59Z</dc:date>
    </item>
    <item>
      <title>GMT YTD flag-- Load problem</title>
      <link>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225788#M78054</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;As per my understanding if the date lies with in the year2date it returns true i.e -1 in your case but when you are comparing with respect to current day it is showing false i.e 0(Zero), i feel u need to mention one parameter called todayaDate in YEARTODATE FORMAT&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i.e&lt;/P&gt;&lt;P&gt;YEARTODATE( DATE [,Yearoffset [ , FirstMonth &lt;STRONG&gt;[ , TodayDate]&lt;/STRONG&gt; ] ])&lt;/P&gt;&lt;P&gt;what i mean is give the Date parameter which is the upper bound of the date i.e As shown below&lt;/P&gt;&lt;P&gt;Year2Date(INVOICE_DATE,0,4,Today()) * -1 &lt;B&gt;as&lt;/B&gt; FY_YTD_Flag&lt;/P&gt;&lt;P&gt;I tried few samples and it has given the following results&lt;/P&gt;&lt;P&gt;Year2Date( '2010-04-29' ,0,4, '2010-04-26' ) Returns Zero which is 0 i.e False&lt;/P&gt;&lt;P&gt;Year2Date( '2010-04-29' ,0,4, '2010-04-26' ) Returns -1 which is True&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try the above things hope this will reslve the prob;lem,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ajay&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Apr 2010 07:21:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225788#M78054</guid>
      <dc:creator>spsrk_84</dc:creator>
      <dc:date>2010-04-29T07:21:03Z</dc:date>
    </item>
    <item>
      <title>GMT YTD flag-- Load problem</title>
      <link>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225789#M78055</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ajay,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your response. I have added this code to my script. I will see how it runs tommorrow morning when Publisher executes the task.&lt;/P&gt;&lt;P&gt;I greatly appreciate your assistance. I will advise.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks Karen&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Apr 2010 13:48:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225789#M78055</guid>
      <dc:creator>karensmith</dc:creator>
      <dc:date>2010-04-29T13:48:57Z</dc:date>
    </item>
    <item>
      <title>GMT YTD flag-- Load problem</title>
      <link>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225790#M78056</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;YearToDate uses the last executed time from the document as its comparison. Your problem is that the last execution time was yesterday at 7am.&lt;/P&gt;&lt;P&gt;So, Ajay's suggestion to use Today() as the date offset would be a good one. Just watch that in his examples he is using "4" as the start month so that depends when your year starts. "4" is April.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Stephen&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Apr 2010 14:12:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225790#M78056</guid>
      <dc:creator>stephencredmond</dc:creator>
      <dc:date>2010-04-29T14:12:21Z</dc:date>
    </item>
    <item>
      <title>GMT YTD flag-- Load problem</title>
      <link>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225791#M78057</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Stephen,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your response. I did make the suggested changes, and now I understand that by leaving out that last parameter that causing my issue.&lt;/P&gt;&lt;P&gt;I greatly appreciate your assitance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks Karen&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Apr 2010 14:21:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/GMT-YTD-flag-Load-problem/m-p/225791#M78057</guid>
      <dc:creator>karensmith</dc:creator>
      <dc:date>2010-04-29T14:21:32Z</dc:date>
    </item>
  </channel>
</rss>

