<?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: Re: Re: How to write Set analysis to get YTD in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554995#M207333</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Isaac,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I see what you mean now... Please have a look.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 30 Aug 2013 16:22:33 GMT</pubDate>
    <dc:creator>cesaraccardi</dc:creator>
    <dc:date>2013-08-30T16:22:33Z</dc:date>
    <item>
      <title>How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554988#M207326</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have the following table:&lt;/P&gt;&lt;P&gt;Table1:&lt;/P&gt;&lt;P&gt;load * Inline&lt;/P&gt;&lt;P&gt;[YearMonth, Revenue&lt;/P&gt;&lt;P&gt;'2013/1/1',100&lt;/P&gt;&lt;P&gt;'2013/2/1',200&lt;/P&gt;&lt;P&gt;'2013/3/1',300&lt;/P&gt;&lt;P&gt;'2013/4/1',400&lt;/P&gt;&lt;P&gt;'2013/5/1',500&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to use one Pivot table to show the YTD revenue, take example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;YearMonth,Revenue&lt;/P&gt;&lt;P&gt;'2013/1/1',100&lt;/P&gt;&lt;P&gt;'2013/2/1',300&lt;/P&gt;&lt;P&gt;'2013/3/1',600&lt;/P&gt;&lt;P&gt;'2013/4/1',1000&lt;/P&gt;&lt;P&gt;'2013/5/1',1500&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I use this expression to finish, but it failed...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=sum({&amp;lt;YearMonth={'&amp;lt;=$(=Only(YearMonth))'}&amp;gt;}TOTAL Revenue)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How can I use Set analysis to achieve it?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 15:24:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554988#M207326</guid>
      <dc:creator />
      <dc:date>2013-08-30T15:24:01Z</dc:date>
    </item>
    <item>
      <title>Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554989#M207327</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Isaac,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think the issue is with the Date format that you have chosen, it is probably dividing 2013 by 5 then by 1 instead of comparing with the full date "2013/5/1". You could either change the format to DD/MM/YYYY or try to apply a formatting function in your expression, something like:&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;"&gt;=sum({&amp;lt;YearMonth={"&amp;lt;=$(=Date#(Only(YearMonth),'YYYY/M/D'))"}&amp;gt;}TOTAL Revenue)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&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;"&gt;Kind Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&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;"&gt;Cesar&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 15:34:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554989#M207327</guid>
      <dc:creator>cesaraccardi</dc:creator>
      <dc:date>2013-08-30T15:34:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554990#M207328</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for your reply, but it does not work, the problem I know is the YearMonth can be captured if we select one option in YearMonth listbox. But if we don't choose any option in YearMonth, the expression does not work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So the key point is how can we capture the current YearMonth for each row in Pivot table?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 15:38:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554990#M207328</guid>
      <dc:creator />
      <dc:date>2013-08-30T15:38:29Z</dc:date>
    </item>
    <item>
      <title>Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554991#M207329</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Isaac,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you add the expression "Only(YearMonth)" you should see the current YearMonth for each row (if you have YearMonth as a dimension or another field in the same level of aggregation). If that's true the issue is related to the comparison &amp;lt;= and the date format.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Are you able to post the application so I can have a look?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cesar&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 15:47:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554991#M207329</guid>
      <dc:creator>cesaraccardi</dc:creator>
      <dc:date>2013-08-30T15:47:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554992#M207330</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;If you are fine with using a straight table and no set analysis.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Abey&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 15:53:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554992#M207330</guid>
      <dc:creator>abeyphilip</dc:creator>
      <dc:date>2013-08-30T15:53:12Z</dc:date>
    </item>
    <item>
      <title>Re: Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554993#M207331</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It is enclosed...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 16:08:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554993#M207331</guid>
      <dc:creator />
      <dc:date>2013-08-30T16:08:36Z</dc:date>
    </item>
    <item>
      <title>Re: Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554994#M207332</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks. but the my question has to be solved by Set analysis.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 16:17:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554994#M207332</guid>
      <dc:creator />
      <dc:date>2013-08-30T16:17:45Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554995#M207333</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Isaac,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I see what you mean now... Please have a look.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 16:22:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554995#M207333</guid>
      <dc:creator>cesaraccardi</dc:creator>
      <dc:date>2013-08-30T16:22:33Z</dc:date>
    </item>
    <item>
      <title>Re: Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554996#M207334</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, it is close to what I wanted. However, the report you provided: the YearMonth listbox does not work, how can the user chooses the YearMonth and also show the right YTD revenue?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 16:31:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554996#M207334</guid>
      <dc:creator />
      <dc:date>2013-08-30T16:31:23Z</dc:date>
    </item>
    <item>
      <title>Re: Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554997#M207335</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, the way I did will always display all the MonthYear values in the table regardless of selections. What is your requirement? Do you need to show all months or only the latest one in the table?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 16:42:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554997#M207335</guid>
      <dc:creator>cesaraccardi</dc:creator>
      <dc:date>2013-08-30T16:42:21Z</dc:date>
    </item>
    <item>
      <title>Re: Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554998#M207336</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What I want is: If the user just chooses 2013-3-1 and 2013-4-1,&amp;nbsp; the pivot table should show 2 rows:&amp;nbsp; the YTD revenue to 2013-3-1and the YTD revenue to 2013-4-1.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 16:45:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554998#M207336</guid>
      <dc:creator />
      <dc:date>2013-08-30T16:45:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to write Set analysis to get YTD</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554999#M207337</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Issac,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Considering you want to evaluate your "Expression's - Set Analysis" in the context of the dimension, &lt;/P&gt;&lt;P&gt;a way to achieve it, would be by using an IF clause. Checkout the attached application. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If it meets your requirements&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;, then please do refer to the following article, &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;it also details how you can form the expression dynamically: &lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" href="https://community.qlik.com/docs/DOC-1335"&gt;Evaluating "sets" in the context of a dimension&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH,&lt;/P&gt;&lt;P&gt;KD&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Aug 2013 20:20:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-write-Set-analysis-to-get-YTD/m-p/554999#M207337</guid>
      <dc:creator>kedar_dandekar</dc:creator>
      <dc:date>2013-08-30T20:20:12Z</dc:date>
    </item>
  </channel>
</rss>

