<?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 Leap Year Help in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082754#M360654</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;**I think my issue is to do with &lt;SPAN style="font-size: 13.3333px;"&gt;(vSystemDate)='01/03/2016' and &lt;SPAN style="font-size: 13.3333px;"&gt;(vSystemDate)&amp;gt;'01/03/2016' not working correct;y. I am not sure it see it as a date as when i do this let vtest2= if($(vSystemDate)&amp;gt;='01/03/2016',0,1 the results comes back as 1 even though todays date is after this date....HELP?&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am having issues with 2016 as it's a leap year. &lt;/P&gt;&lt;P&gt;I am using the following to help match day on day for last year. the variable we use to find last years figure is &lt;SPAN style="font-size: 13.3333px;"&gt;vPriorReportingDate.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;This is how we use it.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(CalendarDate)= 0 and GetSelectedCount(YearNxWeek)= 0 ,&lt;/P&gt;&lt;P&gt;sum({&amp;lt;CalendarDate={"&amp;gt;=$(vSystemPriorWeekStartDate) &amp;lt;=$(vPriorWeekEndDate)"}, TransactionDate = {'&amp;lt;=$(=(vPriorReportingDate))'}, CalendarYear = &amp;gt;}REV)&lt;/P&gt;&lt;P&gt;,&lt;/P&gt;&lt;P&gt;sum({&amp;lt;CalendarDate={"$(=concat(distinct DateCompPriorYear,'","'))"},YearNxWeek={"&amp;gt;=$(vSystemPriorYearWeek) &amp;lt;$(vPriorWeekEnd)"},TransactionDate = {'&amp;lt;=$(=(vPriorReportingDate))'}&amp;gt;}REV)&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;This is what it was:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;let vPriorReportingDate = date((AddMonths((today()-1),-12)+1),'DD/MM/YYYY');&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;but because of the leap year monday didn't map to monday so what i need to do is the following for &lt;SPAN style="font-size: 13.3333px;"&gt;vPriorReportingDate:&lt;/SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let vSystemDate = date((today()),'DD/MM/YYYY');&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let vPriorReportingDate = if($(vSystemDate)='01/03/2016',date((AddMonths((today()-2),-12)+2),'DD/MM/YYYY'),&lt;/P&gt;&lt;P&gt;if($(vSystemDate)&amp;gt;'01/03/2016',date((AddMonths((today()-1),-12)+2),'DD/MM/YYYY'),date((AddMonths((today()-1),-12)+1),'DD/MM/YYYY')));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the image below yellow means 2 and green means 1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/116804_Capture.PNG" style="height: 297px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please can anyone help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 03 Mar 2016 13:59:35 GMT</pubDate>
    <dc:creator />
    <dc:date>2016-03-03T13:59:35Z</dc:date>
    <item>
      <title>Leap Year Help</title>
      <link>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082754#M360654</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;**I think my issue is to do with &lt;SPAN style="font-size: 13.3333px;"&gt;(vSystemDate)='01/03/2016' and &lt;SPAN style="font-size: 13.3333px;"&gt;(vSystemDate)&amp;gt;'01/03/2016' not working correct;y. I am not sure it see it as a date as when i do this let vtest2= if($(vSystemDate)&amp;gt;='01/03/2016',0,1 the results comes back as 1 even though todays date is after this date....HELP?&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am having issues with 2016 as it's a leap year. &lt;/P&gt;&lt;P&gt;I am using the following to help match day on day for last year. the variable we use to find last years figure is &lt;SPAN style="font-size: 13.3333px;"&gt;vPriorReportingDate.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;This is how we use it.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(CalendarDate)= 0 and GetSelectedCount(YearNxWeek)= 0 ,&lt;/P&gt;&lt;P&gt;sum({&amp;lt;CalendarDate={"&amp;gt;=$(vSystemPriorWeekStartDate) &amp;lt;=$(vPriorWeekEndDate)"}, TransactionDate = {'&amp;lt;=$(=(vPriorReportingDate))'}, CalendarYear = &amp;gt;}REV)&lt;/P&gt;&lt;P&gt;,&lt;/P&gt;&lt;P&gt;sum({&amp;lt;CalendarDate={"$(=concat(distinct DateCompPriorYear,'","'))"},YearNxWeek={"&amp;gt;=$(vSystemPriorYearWeek) &amp;lt;$(vPriorWeekEnd)"},TransactionDate = {'&amp;lt;=$(=(vPriorReportingDate))'}&amp;gt;}REV)&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;This is what it was:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;let vPriorReportingDate = date((AddMonths((today()-1),-12)+1),'DD/MM/YYYY');&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;but because of the leap year monday didn't map to monday so what i need to do is the following for &lt;SPAN style="font-size: 13.3333px;"&gt;vPriorReportingDate:&lt;/SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let vSystemDate = date((today()),'DD/MM/YYYY');&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let vPriorReportingDate = if($(vSystemDate)='01/03/2016',date((AddMonths((today()-2),-12)+2),'DD/MM/YYYY'),&lt;/P&gt;&lt;P&gt;if($(vSystemDate)&amp;gt;'01/03/2016',date((AddMonths((today()-1),-12)+2),'DD/MM/YYYY'),date((AddMonths((today()-1),-12)+1),'DD/MM/YYYY')));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the image below yellow means 2 and green means 1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/116804_Capture.PNG" style="height: 297px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please can anyone help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Mar 2016 13:59:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082754#M360654</guid>
      <dc:creator />
      <dc:date>2016-03-03T13:59:35Z</dc:date>
    </item>
    <item>
      <title>Re: Leap Year Help</title>
      <link>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082755#M360655</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Wow this seems like some complicated stuff. I don't even know what needs to be resolved. Would you be able to share a sample so that we can relate the description to some real stuff &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Mar 2016 14:14:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082755#M360655</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-03-03T14:14:18Z</dc:date>
    </item>
    <item>
      <title>Re: Leap Year Help</title>
      <link>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082756#M360656</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi sunny&lt;/P&gt;&lt;P&gt;thanks for getting back to me on this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i think my main issue is that its not reading my dates properly when im trying to set the variable for example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;let vSystemDate = date((today()),'DD/MM/YYYY');&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;this equals 03/03/2016&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;however when i use this &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333px;"&gt; let vtest2= if($(vSystemDate)&amp;gt;='01/03/2016',0,1)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;vtest2 comes back as 1, shoudl come back as 0 as its TRUE&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;Happy to share if you cant see any issue with this.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Mar 2016 14:16:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082756#M360656</guid>
      <dc:creator />
      <dc:date>2016-03-03T14:16:48Z</dc:date>
    </item>
    <item>
      <title>Re: Leap Year Help</title>
      <link>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082757#M360657</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Like Sunny said, it's difficult to see where you have which problem. By your first comparing you need single-quotes around the variable, like: &lt;SPAN style="font-size: 13.3333px;"&gt;if(&lt;STRONG&gt;'$(vSystemDate)'&lt;/STRONG&gt;&amp;gt;='01/03/2016',0,1) then your date is a string in this case.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;For your leap-year topic and the getting the same workday from the previous day, see here: &lt;A href="https://community.qlik.com/message/986285"&gt;Re: date of last year same day&lt;/A&gt;&lt;/SPAN&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Mar 2016 14:22:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082757#M360657</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2016-03-03T14:22:15Z</dc:date>
    </item>
    <item>
      <title>Re: Leap Year Help</title>
      <link>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082758#M360658</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If vSystemData is 03/03/2016, why would it equal 01/03/2016 and give 0 (true)?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Mar 2016 14:55:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Leap-Year-Help/m-p/1082758#M360658</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-03-03T14:55:20Z</dc:date>
    </item>
  </channel>
</rss>

