<?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 Re: Using Dates in Set Analysis in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464969#M173666</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Count({$&amp;lt;ReturnDate={'&amp;gt;=$(vDate)'}&amp;gt;} ReturnDate)&lt;/P&gt;&lt;P&gt;This is a formula that works in my applications:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; sum({$&amp;lt;TransDate={'&amp;lt;=$(BSDurationMEnd)'}&amp;gt;} NLValue)&lt;/P&gt;&lt;P&gt;Make sure the date is&amp;nbsp; a date though. If you're not sure try creating a second variable that converts it using Date($(vDate)).&lt;/P&gt;&lt;P&gt;Jonathan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 12 Jun 2013 10:05:22 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2013-06-12T10:05:22Z</dc:date>
    <item>
      <title>Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464967#M173664</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;I'm trying to do something that I think would be fairly simple, but am failing horribly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to use something like &amp;gt;=2010-01-31 in my date field. I have tried this with formulas and variables, using single and double quotes and equals signs all over the place inside and outside of brackets preceded by $ signs etc. Nothing seems to work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a single dimension called Term, that determines how far back I look (with respect to the current date) in terms of data to include in my sum.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I start with vCurrentDate = Max(Total ReturnDate). I then create vStartDate = MonthEnd($(vCurrentDate),-(Term-1)).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I then use the following expression: Count({$&amp;lt;ReturnDate={"$(='&amp;gt;='&amp;amp;$(vDate))"}&amp;gt;} ReturnDate), I get the same value for all Terms (where Term = 1,3,6,12,36,60 say).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Where am I going wrong? Is it my date format i.e. YYYY-MM-DD that is creating problems in Set Analysis?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Joao.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 09:09:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464967#M173664</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T09:09:35Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464968#M173665</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here's an image of the result:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE bgcolor="#ffffff" border="1" cellpadding="2" cellspacing="0" style="font-size: 9pt;"&gt;&lt;TBODY&gt;&lt;TR bgcolor="#f5f5f5"&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;Term&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;MonthEnd(Max(TOTAL ReturnDate),-(Term-1))&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;Count({$&amp;lt;ReturnDate={"&amp;gt;="}&amp;gt;} Return)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR bgcolor="#f5f5f5"&gt;&lt;TD bgcolor="#f5f5f5"&gt;&lt;/TD&gt;&lt;TD bgcolor="#f5f5f5"&gt;&lt;/TD&gt;&lt;TD bgcolor="#f5f5f5"&gt;&lt;STRONG&gt;74&lt;BR /&gt;&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;1&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2013-03-31&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;74&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;3&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2013-01-31&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;74&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;6&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2012-10-31&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;74&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;12&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2012-04-30&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;74&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;36&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2010-04-30&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;74&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;60&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2008-04-30&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;74&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 09:11:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464968#M173665</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T09:11:27Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464969#M173666</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Count({$&amp;lt;ReturnDate={'&amp;gt;=$(vDate)'}&amp;gt;} ReturnDate)&lt;/P&gt;&lt;P&gt;This is a formula that works in my applications:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; sum({$&amp;lt;TransDate={'&amp;lt;=$(BSDurationMEnd)'}&amp;gt;} NLValue)&lt;/P&gt;&lt;P&gt;Make sure the date is&amp;nbsp; a date though. If you're not sure try creating a second variable that converts it using Date($(vDate)).&lt;/P&gt;&lt;P&gt;Jonathan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 10:05:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464969#M173666</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T10:05:22Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464970#M173667</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;Firstly check the date formats whether it is same throughout i.e the variable in which date is stored and the one which you are comparing, in any text object.&lt;/P&gt;&lt;P&gt;Then try this below set analysis .&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;Count({&amp;lt;ReturnDate={"&amp;gt;=$(vDate)"}&amp;gt;} ReturnDate)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it works.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 10:19:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464970#M173667</guid>
      <dc:creator>shreyashetty_ge</dc:creator>
      <dc:date>2013-06-12T10:19:08Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464971#M173668</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Firstly, apologies for jumping from vStartDate to vDate. They are in fact the same and this is a typo.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your suggestions don't work. I think the vStartDate is a date because it formats as one if I leave the formatting as expression default. If I change the formatting to Integer, it shows as a number (as per table below). The first column is just Term. The second is vStartDate (shows nothing). The third and fourth are $(vStartDate) formatted differently (third is default, and fourth is integer). The last column is your suggested formula i.e. Count&lt;SPAN style="font-size: 8pt;"&gt;({$&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;ReturnDate&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={'&amp;gt;=$(vDate)'}&amp;gt;} &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;ReturnDate&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It has now changed from 72 to 0 (I don't know if that helps).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks again.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE bgcolor="#ffffff" border="1" cellpadding="2" cellspacing="0" style="font-size: 9pt;"&gt;&lt;TBODY&gt;&lt;TR bgcolor="#f5f5f5"&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;Term&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;vStartDate&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;MonthEnd(Max(TOTAL ReturnDate),-(Term-1))&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;MonthEnd(Max(TOTAL ReturnDate),-(Term-1))&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;Count&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR bgcolor="#f5f5f5"&gt;&lt;TD bgcolor="#f5f5f5"&gt;&lt;/TD&gt;&lt;TD bgcolor="#f5f5f5"&gt;&lt;/TD&gt;&lt;TD bgcolor="#f5f5f5"&gt;&lt;/TD&gt;&lt;TD bgcolor="#f5f5f5"&gt;&lt;/TD&gt;&lt;TD bgcolor="#f5f5f5"&gt;&lt;STRONG&gt;0&lt;BR /&gt;&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;1&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2013-03-31&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;41365&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;0&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;3&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2013-01-31&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;41306&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;0&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;6&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2012-10-31&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;41214&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;0&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;12&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2012-04-30&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;41030&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;0&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;36&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2010-04-30&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;40299&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;0&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;60&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;2008-04-30&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;39569&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;0&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 11:41:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464971#M173668</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T11:41:27Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464972#M173669</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry, also does not work. Could I be defining my variables wrongly i.e. do I need '=' in them. Perhaps my definitions above were badly stated, but it does seem to produce the correct dates in theother columns. It is somehow just not doing the set analysis with these dates correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any other suggestions?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 11:47:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464972#M173669</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T11:47:05Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464973#M173670</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;Try like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;=Count({&amp;lt;ReturnDate={"&amp;gt;=$(=vDate)"}&amp;gt;} ReturnDate)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;If you need distinct date then use&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;=Count({&amp;lt;ReturnDate={"&amp;gt;=$(=vDate)"}&amp;gt;} DISTINCT ReturnDate)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;Before that check the date formats in date dimension and variable are same.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;Hope this helps you.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;jagan.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 11:50:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464973#M173670</guid>
      <dc:creator>jagan</dc:creator>
      <dc:date>2013-06-12T11:50:18Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464974#M173671</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry, but still doesn't work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How do I check date formats in dimension and variable? They are numbers representing dates i.e. get formatted as dates when displayed but internally stored as numbers (see above).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Will it help if i leave out the day i.e. just compare to YYYY-MM?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Joao&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 12:58:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464974#M173671</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T12:58:58Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464975#M173672</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How about wrapping a date() function around the vDate ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Count({$&amp;lt;ReturnDate={'&amp;gt;=Date($(vDate))'}&amp;gt;} ReturnDate)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Jonathan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 13:25:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464975#M173672</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T13:25:53Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464976#M173673</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have tried that with no effect.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can't understand why this is so difficult when it should be so easy. I must be doing something wrong.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Both my ReturnDate and my variables are definitely dates (numbers), not text! Is this the problem?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Joao.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 13:31:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464976#M173673</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T13:31:02Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464977#M173674</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've also had problems in the past, especially with balance sheet budgeting calculations.&lt;/P&gt;&lt;P&gt;Try taking the &amp;gt; sign away to see if a straight equals test return anything.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Count({$&amp;lt;ReturnDate={'=Date($(vDate))'}&amp;gt;} ReturnDate)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Jonathan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 14:00:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464977#M173674</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T14:00:45Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464978#M173675</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You already have come close to the solution,&amp;nbsp; its your date format which is creating problm. The format of the Vdate and ReturnDate should be same.Also, if you are not using any '='&amp;nbsp; while creating the variable then you use '=' while using it in set analysis.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Jun 2013 06:16:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464978#M173675</guid>
      <dc:creator>shreyashetty_ge</dc:creator>
      <dc:date>2013-06-13T06:16:05Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464979#M173676</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So how do I make the format the same, or how is it creating problems? Please can you suggest a solution?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, your third sentence doesn't appear to be correct. If I change the definition of vDate from MonthEnd(Max(TOTAL ReturnDate),-(Term-1)) to =MonthEnd(Max(TOTAL ReturnDate),-(Term-1)), it stops working altogether i.e. even $(vStartDate) doesn't produce a result.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Joao.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Jun 2013 06:39:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464979#M173676</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-13T06:39:24Z</dc:date>
    </item>
    <item>
      <title>Re: Using Dates in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464980#M173677</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;I've added an example file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Joao.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Jun 2013 06:53:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-Dates-in-Set-Analysis/m-p/464980#M173677</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-13T06:53:37Z</dc:date>
    </item>
  </channel>
</rss>

