<?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 Problem when using date in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701872#M1054721</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 have a problem when using date.&lt;BR /&gt;I explain. I have two fields (DATE_VALIDATION and CALENDAR.DATE) which contain date values in the format 'YYYY-MM-DD'&lt;/P&gt;&lt;P&gt;I want to create a field which contains values from DATE_VALIDATION for the last 6 months from a certain date selected in CALENDAR.DATE.&lt;/P&gt;&lt;P&gt;For that I create two variables : last6month = addmonths(monthend(max(CALENDAR.DATE))+1,-6) and maxDate= max(CALENDAR.DATE).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I then created a selection which has the following expression : if(DATE_VALIDATION &amp;gt;= $(last6month) and DATE_VALIDATION &amp;lt;= $(maxDate),DATE_VALIDATION)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But the selection list shows me no values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Someone can explain it ?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 27 Oct 2014 11:04:11 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-10-27T11:04:11Z</dc:date>
    <item>
      <title>Problem when using date</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701872#M1054721</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 have a problem when using date.&lt;BR /&gt;I explain. I have two fields (DATE_VALIDATION and CALENDAR.DATE) which contain date values in the format 'YYYY-MM-DD'&lt;/P&gt;&lt;P&gt;I want to create a field which contains values from DATE_VALIDATION for the last 6 months from a certain date selected in CALENDAR.DATE.&lt;/P&gt;&lt;P&gt;For that I create two variables : last6month = addmonths(monthend(max(CALENDAR.DATE))+1,-6) and maxDate= max(CALENDAR.DATE).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I then created a selection which has the following expression : if(DATE_VALIDATION &amp;gt;= $(last6month) and DATE_VALIDATION &amp;lt;= $(maxDate),DATE_VALIDATION)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But the selection list shows me no values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Someone can explain it ?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Oct 2014 11:04:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701872#M1054721</guid>
      <dc:creator />
      <dc:date>2014-10-27T11:04:11Z</dc:date>
    </item>
    <item>
      <title>Re: Problem when using date</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701873#M1054722</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When you use max()&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;that time your date field is converted to num format&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;therefore You have convert your Date_validation field in Num format then compare.&lt;/P&gt;&lt;P&gt;Do like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if(DATE_VALIDATION &amp;gt;= $(last6month) and num(DATE_VALIDATION) &amp;lt;= $(maxDate),DATE_VALIDATION)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Oct 2014 11:25:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701873#M1054722</guid>
      <dc:creator>PrashantSangle</dc:creator>
      <dc:date>2014-10-27T11:25:10Z</dc:date>
    </item>
    <item>
      <title>Re: Problem when using date</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701874#M1054723</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Still doesn't work&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Oct 2014 11:30:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701874#M1054723</guid>
      <dc:creator />
      <dc:date>2014-10-27T11:30:35Z</dc:date>
    </item>
    <item>
      <title>Re: Problem when using date</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701875#M1054724</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;make all your date fields numbers&lt;/P&gt;&lt;P&gt;num(dayStart(your_date_field))&lt;/P&gt;&lt;P&gt;use whatever you want then on the chart use the number tab to make the dates readable &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Oct 2014 13:34:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701875#M1054724</guid>
      <dc:creator>ali_hijazi</dc:creator>
      <dc:date>2014-10-27T13:34:19Z</dc:date>
    </item>
    <item>
      <title>Re: Problem when using date</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701876#M1054725</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think I found the problem. I don't know why but it comes from the max function&lt;/P&gt;&lt;P&gt;When I remove max in both variables it works!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Oct 2014 07:15:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-when-using-date/m-p/701876#M1054725</guid>
      <dc:creator />
      <dc:date>2014-10-28T07:15:16Z</dc:date>
    </item>
  </channel>
</rss>

