<?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 statements and set analysis in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283885#M872628</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/people/adamdavi3s"&gt;adamdavi3s&lt;/A&gt;‌ - although that is what I have been made to think also that Pick(Match()) offers a drastic improvement over if statement. But did you ever get a chance to test it out? My intentions are not to say that my expression is better than yours, but recently I switched an if statement with pick match in a relatively bigger application (4GB) hoping to get some better response time. Based on multiple tests, I found out that if was performing slight better than the Pick(Match()). The only good thing was the simplicity of the expression.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Have you ever tested this or is this based on what you have heard and seen?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 21 Nov 2016 12:59:31 GMT</pubDate>
    <dc:creator>sunny_talwar</dc:creator>
    <dc:date>2016-11-21T12:59:31Z</dc:date>
    <item>
      <title>IF statements and set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283879#M872619</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm trying to get a points system running but I want it to only give points if the person is in the certain area.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I know this will include set analysis and the IF statement but can't get it to give the right results as I'm not sure exactly where the set analysis will go. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is the IF statement:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF(sum(Bins)&amp;gt;=300, 50, IF(sum(Bins)&amp;gt;=250, 40, IF(sum(Bins)&amp;gt;=200, 30, IF(sum(Bins)&amp;gt;=150,20, IF(sum(Bins)&amp;gt;=100, 10, 10)))))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And I want to make it so it only shows where AreaName = Materials and the other Area Names will have 0 points.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Which order do I need to make the expression?&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, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283879#M872619</guid>
      <dc:creator>khaycock</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: IF statements and set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283880#M872620</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;PICK(MATCH(AreaName,'Materials')+1,0,&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;IF(sum(Bins)&amp;gt;=300, 50, IF(sum(Bins)&amp;gt;=250, 40, IF(sum(Bins)&amp;gt;=200, 30, IF(sum(Bins)&amp;gt;=150,20, IF(sum(Bins)&amp;gt;=100, 10, 10))))) )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is written on the fly so apologies if it doesn't work first off!&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Match will return 0 (if no match) or 1 (if Materials is the AreaName) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Pick then 'picks' the item from the pick list based on this result, however Pick is 1 based so we need to add one to the result of the match.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, if the AreaName is not equal to 'Materials' the pick formula will return list item 1 (0+1) which is 0&lt;/P&gt;&lt;P&gt;If it is materials then the pick formula will return list item 2 (1+1) which is your IF formula&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Nov 2016 12:30:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283880#M872620</guid>
      <dc:creator>adamdavi3s</dc:creator>
      <dc:date>2016-11-21T12:30:26Z</dc:date>
    </item>
    <item>
      <title>Re: IF statements and set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283881#M872622</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: #ff0000;"&gt;If(AreaName = 'Materials',&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: #3d3d3d; font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;If(sum(Bins)&amp;gt;=300, 50,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: #3d3d3d; font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;If(sum(Bins)&amp;gt;=250, 40,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: #3d3d3d; font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;If(sum(Bins)&amp;gt;=200, 30,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: #3d3d3d; font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;If(sum(Bins)&amp;gt;=150, 20,&lt;/STRONG&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;"&gt;&lt;STRONG&gt;If(sum(Bins)&amp;gt;=100, 10, 10)))))&lt;SPAN style="color: #ff0000;"&gt;, 0)&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Nov 2016 12:32:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283881#M872622</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-11-21T12:32:16Z</dc:date>
    </item>
    <item>
      <title>Re: IF statements and set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283882#M872623</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Spot on, thank you!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Nov 2016 12:32:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283882#M872623</guid>
      <dc:creator>khaycock</dc:creator>
      <dc:date>2016-11-21T12:32:27Z</dc:date>
    </item>
    <item>
      <title>Re: IF statements and set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283883#M872625</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try something like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;IF(sum({&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;AreaName = {'Materials'} and AreaName = $::P(AreaName = {"$(=Len(AreaName) = 0)"})&lt;/SPAN&gt;&amp;gt;} Bins)&amp;gt;=300, 50, IF(sum(&lt;STRONG style="font-size: 13.3333px;"&gt;{&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;AreaName = {'Materials'} and AreaName = $::P(AreaName = {"$(=Len(AreaName) = 0)"})&lt;/SPAN&gt;&amp;gt;}&lt;/STRONG&gt;&lt;STRONG style="font-size: 13.3333px;"&gt; &lt;/STRONG&gt;Bins)&amp;gt;=250, 40, IF(&lt;STRONG style="font-size: 13.3333px;"&gt;{&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;AreaName = {'Materials'} and AreaName = $::P(AreaName = {"$(=Len(AreaName) = 0)"})&lt;/SPAN&gt;&amp;gt;}&lt;/STRONG&gt;&lt;STRONG style="font-size: 13.3333px;"&gt; &lt;/STRONG&gt;Bins)&amp;gt;=200, 30, IF(sum(&lt;STRONG style="font-size: 13.3333px;"&gt;{&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;AreaName = {'Materials'} and AreaName = $::P(AreaName = {"$(=Len(AreaName) = 0)"})&lt;/SPAN&gt;&amp;gt;}&lt;/STRONG&gt;&lt;STRONG style="font-size: 13.3333px;"&gt; &lt;/STRONG&gt;Bins)&amp;gt;=150,20, IF(sum(&lt;STRONG style="font-size: 13.3333px;"&gt;{&amp;lt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;AreaName = {'Materials'} and AreaName = $::P(AreaName = {"$(=Len(AreaName) = 0)"})&lt;/SPAN&gt;&amp;gt;}&lt;/STRONG&gt;&lt;STRONG style="font-size: 13.3333px;"&gt; &lt;/STRONG&gt;Bins)&amp;gt;=100, 10, 10)))))&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Nov 2016 12:37:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283883#M872625</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2016-11-21T12:37:25Z</dc:date>
    </item>
    <item>
      <title>Re: IF statements and set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283884#M872627</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not a problem at all, Pick(Match( is a very handy combination and in larger apps it out performs IF by a large margin &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Nov 2016 12:44:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283884#M872627</guid>
      <dc:creator>adamdavi3s</dc:creator>
      <dc:date>2016-11-21T12:44:42Z</dc:date>
    </item>
    <item>
      <title>Re: IF statements and set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283885#M872628</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/people/adamdavi3s"&gt;adamdavi3s&lt;/A&gt;‌ - although that is what I have been made to think also that Pick(Match()) offers a drastic improvement over if statement. But did you ever get a chance to test it out? My intentions are not to say that my expression is better than yours, but recently I switched an if statement with pick match in a relatively bigger application (4GB) hoping to get some better response time. Based on multiple tests, I found out that if was performing slight better than the Pick(Match()). The only good thing was the simplicity of the expression.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Have you ever tested this or is this based on what you have heard and seen?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Nov 2016 12:59:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283885#M872628</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-11-21T12:59:31Z</dc:date>
    </item>
    <item>
      <title>Re: IF statements and set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283886#M872630</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Based on my experience yes it is a lot faster, this does however go back to version 10 and I haven't re-tested it since moving to 12.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We had a chart which would not calculate with an IF, with pick(match( it absolutely flies. The dashboard is probably running to about 3gb but the formula is quite intensive with several nested IF&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;This change was made on the basis of advice from a Qlik Consultant we spent a day with and we haven't looked back since.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Based on this real world experience I would always advocate the use of pick match in larger applications especially where there are a number of nested IFs&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Nov 2016 13:05:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283886#M872630</guid>
      <dc:creator>adamdavi3s</dc:creator>
      <dc:date>2016-11-21T13:05:55Z</dc:date>
    </item>
    <item>
      <title>Re: IF statements and set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283887#M872631</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not sure why I did not see any performance benefits. Will try to do some more digging when I will get some time.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 21 Nov 2016 13:08:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/IF-statements-and-set-analysis/m-p/1283887#M872631</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-11-21T13:08:51Z</dc:date>
    </item>
  </channel>
</rss>

