<?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: Trend based on nested if in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377439#M814754</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Check this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Len(Trim(After(Sum(Margin)/Sum(Sales)))) &amp;gt; 0 or Len(Trim(Sum(Margin)/Sum(Sales))) &amp;gt; 0,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Round(Alt(After(Sum(Margin)/Sum(Sales)), 0), 0.0001) &amp;gt; Round(Alt(Sum(Margin)/Sum(Sales), 0), 0.0001), 'qmem://&amp;lt;bundled&amp;gt;/BuiltIn/arrow_n_g.png',&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Round(Alt(Sum(Margin)/Sum(Sales), 0), 0.0001) = Round(Alt(After(Sum(Margin)/Sum(Sales)), 0), 0.0001), 'qmem://&amp;lt;bundled&amp;gt;/BuiltIn/arrow_e.png', 'qmem://&amp;lt;bundled&amp;gt;/BuiltIn/arrow_s_r.png')))&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 20 Sep 2017 15:35:30 GMT</pubDate>
    <dc:creator>sunny_talwar</dc:creator>
    <dc:date>2017-09-20T15:35:30Z</dc:date>
    <item>
      <title>Trend based on nested if</title>
      <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377435#M814748</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 am having trouble building a expression.&lt;/P&gt;&lt;P&gt;I have a pivot table with month as horizontal dimension and the expression is sum(Margin)/sum(Sales). I want to show &lt;STRONG&gt;up/down/Horizontal arrow&lt;/STRONG&gt; in second expression, based on &lt;STRONG&gt;below conditions&lt;/STRONG&gt;-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1)If Feb is &amp;gt; Jan then show UP Arrow.&lt;/P&gt;&lt;P&gt;2)If Feb is Equal to Jan then show UP Arrow when both are 100%. If both are Equal but less than 100% then show horizontal arrow. &lt;/P&gt;&lt;P&gt;Eg- Both Feb is 38% and Jan is 38% then show horizontal arrow.&lt;/P&gt;&lt;P&gt;Also, i want to apply rounding of 0.005 on Feb. ie. if Feb is within threshold of 0.005 then it will be considered equal to Jan so show horizontal arrow or UP arrow if both are 100% after rounding on Feb.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3)If Feb is &amp;lt; than jan show Down Arrow.&lt;/P&gt;&lt;P&gt;4)If latest month ie.Feb is null, then Down arrow&lt;/P&gt;&lt;P&gt;5)If Previous month ie. Jan is null and Feb has value then show UP arrow&lt;/P&gt;&lt;P&gt;6) If both Jan and Feb is null then show blank/null&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have build the below expression, but it is not working.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=if(After(sum(Margin)/sum(Sales)) &amp;gt; (sum(Margin)/sum(Sales)),'qmem://&amp;lt;bundled&amp;gt;/BuiltIn/arrow_n_g.png',&lt;/P&gt;&lt;P&gt;if((sum(Margin)/sum(Sales)) = Round(After(sum(Margin)/sum(Sales)),'0.005'),'qmem://&amp;lt;bundled&amp;gt;/BuiltIn/arrow_e.png',&lt;/P&gt;&lt;P&gt;'qmem://&amp;lt;bundled&amp;gt;/BuiltIn/arrow_s_r.png'))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I really appreciate if anyone could help me.&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/Trend-based-on-nested-if/m-p/1377435#M814748</guid>
      <dc:creator>surajdhall</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: Trend based on nested if</title>
      <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377436#M814750</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Which of arrows not working? Can you point out?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Sep 2017 00:23:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377436#M814750</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-09-20T00:23:26Z</dc:date>
    </item>
    <item>
      <title>Re: Trend based on nested if</title>
      <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377437#M814752</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Suraj,&lt;/P&gt;&lt;P&gt;According ur conditions given; arrows are working fine to me.&lt;/P&gt;&lt;P&gt;Rgds,&lt;/P&gt;&lt;P&gt;Tharindu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Sep 2017 04:08:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377437#M814752</guid>
      <dc:creator>dinuwanbr</dc:creator>
      <dc:date>2017-09-20T04:08:54Z</dc:date>
    </item>
    <item>
      <title>Re: Trend based on nested if</title>
      <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377438#M814753</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;&lt;/P&gt;&lt;P&gt;-&lt;STRONG&gt;2nd row&lt;/STRONG&gt; is going UP. I expect it to go Horizontal.&lt;/P&gt;&lt;P&gt;-&lt;STRONG&gt;8th row&lt;/STRONG&gt;(Product H), i expect to go UP, as Jan has no data and Feb has Data&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;-&lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;STRONG&gt;9th row&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;(Product I), i expect to show blank, as both jan and feb data is not present.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;-Also all arrows in Feb is going DOWN, as there is no march data, the column show show blank.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also when I add below 2 rows to inline load, I see they give 100% in both jan and feb but shows DOWN arrow, instead of horizontal arrow.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; H, 01/01/2017, 11983605, 11983879&lt;BR /&gt; H, 01/02/2017, 11590671, 11590945&lt;BR /&gt; ] &lt;/P&gt;&lt;P&gt;&lt;SPAN class="mce_paste_marker"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regarding the round(), I am not sure if the round() I did on the new month is correct. Do i have to do Round() on both New and Previous month like below. My requirement is to bring Feb near to Jan to see if both match, if they match show Horzontal arrow.&lt;/P&gt;&lt;P&gt;Round(sum(Margin)/sum(Sales)),'0.005') = Round(After(sum(Margin)/sum(Sales)),'0.005')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Thanks!&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Sep 2017 07:00:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377438#M814753</guid>
      <dc:creator>surajdhall</dc:creator>
      <dc:date>2017-09-20T07:00:54Z</dc:date>
    </item>
    <item>
      <title>Re: Trend based on nested if</title>
      <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377439#M814754</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Check this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Len(Trim(After(Sum(Margin)/Sum(Sales)))) &amp;gt; 0 or Len(Trim(Sum(Margin)/Sum(Sales))) &amp;gt; 0,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Round(Alt(After(Sum(Margin)/Sum(Sales)), 0), 0.0001) &amp;gt; Round(Alt(Sum(Margin)/Sum(Sales), 0), 0.0001), 'qmem://&amp;lt;bundled&amp;gt;/BuiltIn/arrow_n_g.png',&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Round(Alt(Sum(Margin)/Sum(Sales), 0), 0.0001) = Round(Alt(After(Sum(Margin)/Sum(Sales)), 0), 0.0001), 'qmem://&amp;lt;bundled&amp;gt;/BuiltIn/arrow_e.png', 'qmem://&amp;lt;bundled&amp;gt;/BuiltIn/arrow_s_r.png')))&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Sep 2017 15:35:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377439#M814754</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-09-20T15:35:30Z</dc:date>
    </item>
    <item>
      <title>Re: Trend based on nested if</title>
      <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377440#M814755</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you so much.&lt;/P&gt;&lt;P&gt;The expression seems working, I will try this in the mail application and get back in few minutes&lt;/P&gt;&lt;P&gt;But I am just wondering why did you round with 0.0001?. My requirement is to round using 0.005. Is it ok to use 0.0001?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Sep 2017 21:49:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377440#M814755</guid>
      <dc:creator>surajdhall</dc:creator>
      <dc:date>2017-09-20T21:49:36Z</dc:date>
    </item>
    <item>
      <title>Re: Trend based on nested if</title>
      <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377441#M814756</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Rounding to 0.005 was not working for what you wanted your arrows to do.... besides 0.0001 is rounding the percentage to two decimals... meaning&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;10.344523 % = 0.10344523... do you want this to be 10.34% or 10.5%? because 0.005 will round the number to 10.5% making it more forgiving in matching the values... is that what you want?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Sep 2017 22:22:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377441#M814756</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-09-20T22:22:04Z</dc:date>
    </item>
    <item>
      <title>Re: Trend based on nested if</title>
      <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377442#M814757</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for you suggestion.&lt;/P&gt;&lt;P&gt;I want 2 decimals in percentage &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;10.34%. &lt;/SPAN&gt;I will go with 0.0001 as you suggested.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;One final help.&amp;nbsp; &lt;SPAN style="font-size: 10pt;"&gt;I want to show 2 overall trend columns for High &amp;amp; Low( as per below conditions) beside the Product dimension, like below image. As it is pivot table, i cannot able to create as expression, so i hope it would be calculated dimension using Aggr(), but not sure what conditions to put, as there columns are only for display purpose.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;IMG __jive_id="177208" alt="trend image.png" class="jive-image image-1" src="/legacyfs/online/177208_trend image.png" style="height: auto;" /&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;The conditions are-&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;If no Down arrows for the Product and Status, then show 'Good trend'&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;If Down arrows are less then 2, show 'positive trend'&lt;/P&gt;&lt;P&gt;If Down arrows are greater than 1, show 'Average Trend'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I added the status column in the app.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please suggest.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Sep 2017 22:55:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377442#M814757</guid>
      <dc:creator>surajdhall</dc:creator>
      <dc:date>2017-09-20T22:55:03Z</dc:date>
    </item>
    <item>
      <title>Re: Trend based on nested if</title>
      <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377443#M814758</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Like this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/177232_Capture.PNG" style="height: 217px; width: 620px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Sep 2017 01:33:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377443#M814758</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-09-21T01:33:07Z</dc:date>
    </item>
    <item>
      <title>Re: Trend based on nested if</title>
      <link>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377444#M814759</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you so much for the help&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Sep 2017 22:39:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Trend-based-on-nested-if/m-p/1377444#M814759</guid>
      <dc:creator>surajdhall</dc:creator>
      <dc:date>2017-09-21T22:39:05Z</dc:date>
    </item>
  </channel>
</rss>

