<?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: Nested If statements in straight table in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Nested-If-statements-in-straight-table/m-p/1033285#M640348</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mike,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the problem is caused by the logical condition &lt;STRONG&gt;Time = 'Month'.&lt;/STRONG&gt; When it's used in the Monthly chart, it renders True only for selected (or available) Months, and it renders False for the excluded (unavailable) months. So, when it's False, it looks like the selection of Months is ignored, when in fact it's just the condition that doesn't work correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The fix is rather simple: replace your existing conditions with this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;only(total Time) = 'Month'&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and everything will work correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Oleg Troyansky&lt;/P&gt;&lt;P&gt;Upgrade your Qlik skills at the &lt;A href="http://masterssummit.com/"&gt;Masters Summit for Qlik&lt;/A&gt; - coming soon to Milan, Italy!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 02 Feb 2016 22:29:14 GMT</pubDate>
    <dc:creator>Oleg_Troyansky</dc:creator>
    <dc:date>2016-02-02T22:29:14Z</dc:date>
    <item>
      <title>Nested If statements in straight table</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-If-statements-in-straight-table/m-p/1033283#M640346</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all, I am trying to set up a straight table that has multiple dimensions based on a field called Time. Basically if I choose Time = 'Year' then I want Month and Quarter calendar functions to be ignored. Also, if I choose Time='Quarter' I want Month to be ignored.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This expression works perfectly in a text box, but it defaults to the last &lt;EM&gt;Then&lt;/EM&gt; statement in the straight table, in bold. Because of this, no matter what selection I make in Time, Month and Quarter are being excluded, which is not what I want.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is&amp;nbsp; aggregated value&lt;/P&gt;&lt;P&gt;=if(Time = 'Month', Sum({$&amp;lt; Metric = {'New Business USD'}&amp;gt;}&amp;nbsp; Value),&lt;/P&gt;&lt;P&gt;&amp;nbsp; if(Time = 'Quarter', Sum({$&amp;lt; Metric = {'New Business USD'}, Month=&amp;gt;}&amp;nbsp; Value),&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;STRONG&gt;Sum({$&amp;lt; Metric = {'New Business USD'}, Month=, Quarter=&amp;gt;}&amp;nbsp; Value)&lt;/STRONG&gt;))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Point to point&lt;/P&gt;&lt;P&gt;=if(Time = 'Month', FirstSortedValue({&amp;lt;Metric = {'30+%'}&amp;gt;} Value, -MonthYear),&lt;/P&gt;&lt;P&gt;&amp;nbsp; if(Time = 'Quarter', FirstSortedValue({&amp;lt;Metric = {'30+%'},Month=&amp;gt;} Value, -MonthYear),&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; FirstSortedValue({&amp;lt;Metric = {'30+%'},Month=,Quarter=&amp;gt;} Value, -MonthYear)&lt;/STRONG&gt;))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example with nested if's attached.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Feb 2016 21:25:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-If-statements-in-straight-table/m-p/1033283#M640346</guid>
      <dc:creator />
      <dc:date>2016-02-02T21:25:57Z</dc:date>
    </item>
    <item>
      <title>Re: Nested If statements in straight table</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-If-statements-in-straight-table/m-p/1033284#M640347</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are you saying that when you click on Month, you want to see Quarter and Year as dimensions and when you click on Quarter you would want to see Year as a dimension also? I am having hard time understanding what the required output needs to be. Would you be able to clarify?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Feb 2016 21:45:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-If-statements-in-straight-table/m-p/1033284#M640347</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-02-02T21:45:41Z</dc:date>
    </item>
    <item>
      <title>Re: Nested If statements in straight table</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-If-statements-in-straight-table/m-p/1033285#M640348</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mike,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the problem is caused by the logical condition &lt;STRONG&gt;Time = 'Month'.&lt;/STRONG&gt; When it's used in the Monthly chart, it renders True only for selected (or available) Months, and it renders False for the excluded (unavailable) months. So, when it's False, it looks like the selection of Months is ignored, when in fact it's just the condition that doesn't work correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The fix is rather simple: replace your existing conditions with this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;only(total Time) = 'Month'&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and everything will work correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Oleg Troyansky&lt;/P&gt;&lt;P&gt;Upgrade your Qlik skills at the &lt;A href="http://masterssummit.com/"&gt;Masters Summit for Qlik&lt;/A&gt; - coming soon to Milan, Italy!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Feb 2016 22:29:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-If-statements-in-straight-table/m-p/1033285#M640348</guid>
      <dc:creator>Oleg_Troyansky</dc:creator>
      <dc:date>2016-02-02T22:29:14Z</dc:date>
    </item>
    <item>
      <title>Re: Nested If statements in straight table</title>
      <link>https://community.qlik.com/t5/QlikView/Nested-If-statements-in-straight-table/m-p/1033286#M640349</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Oleg, This works perfectly!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Feb 2016 14:44:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Nested-If-statements-in-straight-table/m-p/1033286#M640349</guid>
      <dc:creator />
      <dc:date>2016-02-03T14:44:19Z</dc:date>
    </item>
  </channel>
</rss>

