<?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: 'IF' Function in Set Analysis in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450837#M485522</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you very much for your reply Gysbert,&lt;/P&gt;&lt;P&gt;this comment gave me the idea of an alternative path to follow.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have added a new dimension Date as calculated by the IF function&lt;/P&gt;&lt;P&gt;directly to the Fact table. Then I guess I will be able to use it in the set analysis but &lt;/P&gt;&lt;P&gt;I could not try it all yet. I'll try tomorrow the rest in the office.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Even if I have a pretty huge application I think is&lt;/P&gt;&lt;P&gt;a good way to go and when all will work I will try reducing the size of it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank again!&lt;/P&gt;&lt;P&gt;Alen&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 14 Apr 2013 21:37:23 GMT</pubDate>
    <dc:creator>tedalien</dc:creator>
    <dc:date>2013-04-14T21:37:23Z</dc:date>
    <item>
      <title>'IF' Function in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450834#M485519</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Hello everyone of the community,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;I started since few months using Qlikview as developer and even if I am reading a bunch of books and articles I see that there is a long learning path in front of me. However I am fascinated by Qlikview and I am glad that there is a forum like this full of enthusiastic users.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;I have a conceptual question regarding &lt;STRONG&gt;set analysis &lt;/STRONG&gt;and the &lt;STRONG&gt;function IF&lt;/STRONG&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;I tried an expresssion like the one below but the syntax seems not well taken and it produces no results ('-').&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;Expression:&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;sum ({1&amp;lt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;SPAN style="color: #008000;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff;"&gt;if &lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;[Order]&lt;/SPAN&gt;='Billed',&lt;SPAN style="color: #800000;"&gt;[Billing Date]&lt;/SPAN&gt;,&lt;SPAN style="color: #800000;"&gt;[Order Date]&lt;/SPAN&gt;)={&lt;SPAN style="color: #800000;"&gt;"$(=date([ReportingDate],'YYYYMM'))"&lt;/SPAN&gt;}&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&amp;gt;}IF(&lt;SPAN style="color: #800000;"&gt;[Unit]&lt;/SPAN&gt;='MT',&lt;SPAN style="color: #800000;"&gt;[Order Quantity]&lt;/SPAN&gt;*1000,&lt;SPAN style="color: #800000;"&gt;[Order Quantity]&lt;/SPAN&gt;))&lt;BR /&gt;&lt;BR /&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;My &lt;STRONG&gt;question &lt;/STRONG&gt;is a &lt;STRONG&gt;general one&lt;/STRONG&gt;:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #ff0000; font-size: 10pt;"&gt;&lt;STRONG&gt;Can I use nested IF in a Set Analysis?&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Apologies if I missed a past reply on this topic but I did not find it on the search.&lt;/P&gt;&lt;P&gt;In this case how would much appreciate if you can re-direct me to the appropriate thread!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Many Thanks for your support,&lt;/P&gt;&lt;P&gt;Alen&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Apr 2013 17:27:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450834#M485519</guid>
      <dc:creator>tedalien</dc:creator>
      <dc:date>2013-04-12T17:27:29Z</dc:date>
    </item>
    <item>
      <title>Re: 'IF' Function in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450835#M485520</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What you're trying isn't going to work because the set is calculated first and then the dimensions and expressions of the chart are applied to the calculated set. The set is calculated once for the chart, not per row. So the if statement in the set modifier isn't going to work. If ReportingDate is a field then comparing it with either Billing Date of Order Date won't do what you expect either.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 13 Apr 2013 07:59:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450835#M485520</guid>
      <dc:creator>Gysbert_Wassenaar</dc:creator>
      <dc:date>2013-04-13T07:59:34Z</dc:date>
    </item>
    <item>
      <title>Re: 'IF' Function in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450836#M485521</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;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Yes you can use if statement like shown below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; sum({&amp;lt;[$(=if(Status='A',Date1,Date2))] = {"&amp;lt;=$(=makedate(2012,10,01))"}&amp;gt;}Sales)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; But for this there should be a selection in the Field Status.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; If you dont select the status it will not work, but still you can use few more functions to avoid selection too.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kaushik Solanki&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 13 Apr 2013 08:03:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450836#M485521</guid>
      <dc:creator>kaushiknsolanki</dc:creator>
      <dc:date>2013-04-13T08:03:55Z</dc:date>
    </item>
    <item>
      <title>Re: 'IF' Function in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450837#M485522</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you very much for your reply Gysbert,&lt;/P&gt;&lt;P&gt;this comment gave me the idea of an alternative path to follow.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have added a new dimension Date as calculated by the IF function&lt;/P&gt;&lt;P&gt;directly to the Fact table. Then I guess I will be able to use it in the set analysis but &lt;/P&gt;&lt;P&gt;I could not try it all yet. I'll try tomorrow the rest in the office.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Even if I have a pretty huge application I think is&lt;/P&gt;&lt;P&gt;a good way to go and when all will work I will try reducing the size of it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank again!&lt;/P&gt;&lt;P&gt;Alen&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 14 Apr 2013 21:37:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450837#M485522</guid>
      <dc:creator>tedalien</dc:creator>
      <dc:date>2013-04-14T21:37:23Z</dc:date>
    </item>
    <item>
      <title>Re: 'IF' Function in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450838#M485523</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kaushik,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thank you for your Reply. I m not sure I fully understand what you mean.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I try this the syntax automaitcally consider the "&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;$(=if(Status&lt;/SPAN&gt;" as Variable.&lt;/P&gt;&lt;P&gt;Is this what you mean to use a Variable?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For the moment I am testing how it comes adding a dimension to my fact table with the field already&lt;/P&gt;&lt;P&gt;calculated at lines level. Not really a "saving Kbit" solution but I think is worth to check it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Alen&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 14 Apr 2013 21:40:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-Function-in-Set-Analysis/m-p/450838#M485523</guid>
      <dc:creator>tedalien</dc:creator>
      <dc:date>2013-04-14T21:40:47Z</dc:date>
    </item>
  </channel>
</rss>

