<?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 Measure Expression Not Limiting To Positives In Pivot Table in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Measure-Expression-Not-Limiting-To-Positives-In-Pivot-Table/m-p/1934420#M76972</link>
    <description>&lt;P&gt;In a pivot table, the following expression is not limiting to positive values. Any idea why? The plain text is also below; screenshot with cleaner formatting follows. The pivot table column is Year_Placed. The rows are a different (higher-level) field.&lt;/P&gt;
&lt;P&gt;sum( aggr(if(&lt;/P&gt;
&lt;P&gt;(sum( if( Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/ and placedt_all=aggr( nodistinct &lt;BR /&gt;max( if(Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr */, placedt_all)),acctpol, Year_Placed), Placed))&lt;BR /&gt;+&lt;BR /&gt;sum( if( Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/&lt;BR /&gt;and placedt_all=aggr($ nodistinct &lt;BR /&gt;max( if( Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/, placedt_all)),acctpol, Year_Placed) , Adjustment))) &amp;gt; 0,&lt;BR /&gt;&lt;BR /&gt;sum( if(Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/ and placedt_all=aggr( nodistinct &lt;BR /&gt;max( if( Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/, placedt_all)),acctpol, Year_Placed), Placed))&lt;BR /&gt;+&lt;BR /&gt;sum( if( Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/&lt;BR /&gt;and placedt_all=aggr( nodistinct &lt;BR /&gt;max( if( Month_Placed &amp;lt;= CurrMonth /* and Year_Placed = CurrYr*/ , placedt_all)),acctpol, Year_Placed) , Adjustment)), 0), acctpol, Year_Placed))&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2022-05-23_14-17-55.jpg" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/80096iF25691D1BB03973F/image-size/large?v=v2&amp;amp;px=999" role="button" title="2022-05-23_14-17-55.jpg" alt="2022-05-23_14-17-55.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 23 May 2022 18:19:55 GMT</pubDate>
    <dc:creator>newuser</dc:creator>
    <dc:date>2022-05-23T18:19:55Z</dc:date>
    <item>
      <title>Measure Expression Not Limiting To Positives In Pivot Table</title>
      <link>https://community.qlik.com/t5/App-Development/Measure-Expression-Not-Limiting-To-Positives-In-Pivot-Table/m-p/1934420#M76972</link>
      <description>&lt;P&gt;In a pivot table, the following expression is not limiting to positive values. Any idea why? The plain text is also below; screenshot with cleaner formatting follows. The pivot table column is Year_Placed. The rows are a different (higher-level) field.&lt;/P&gt;
&lt;P&gt;sum( aggr(if(&lt;/P&gt;
&lt;P&gt;(sum( if( Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/ and placedt_all=aggr( nodistinct &lt;BR /&gt;max( if(Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr */, placedt_all)),acctpol, Year_Placed), Placed))&lt;BR /&gt;+&lt;BR /&gt;sum( if( Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/&lt;BR /&gt;and placedt_all=aggr($ nodistinct &lt;BR /&gt;max( if( Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/, placedt_all)),acctpol, Year_Placed) , Adjustment))) &amp;gt; 0,&lt;BR /&gt;&lt;BR /&gt;sum( if(Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/ and placedt_all=aggr( nodistinct &lt;BR /&gt;max( if( Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/, placedt_all)),acctpol, Year_Placed), Placed))&lt;BR /&gt;+&lt;BR /&gt;sum( if( Month_Placed &amp;lt;= CurrMonth /*and Year_Placed = CurrYr*/&lt;BR /&gt;and placedt_all=aggr( nodistinct &lt;BR /&gt;max( if( Month_Placed &amp;lt;= CurrMonth /* and Year_Placed = CurrYr*/ , placedt_all)),acctpol, Year_Placed) , Adjustment)), 0), acctpol, Year_Placed))&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2022-05-23_14-17-55.jpg" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/80096iF25691D1BB03973F/image-size/large?v=v2&amp;amp;px=999" role="button" title="2022-05-23_14-17-55.jpg" alt="2022-05-23_14-17-55.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 23 May 2022 18:19:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Measure-Expression-Not-Limiting-To-Positives-In-Pivot-Table/m-p/1934420#M76972</guid>
      <dc:creator>newuser</dc:creator>
      <dc:date>2022-05-23T18:19:55Z</dc:date>
    </item>
    <item>
      <title>Re: Measure Expression Not Limiting To Positives In Pivot Table</title>
      <link>https://community.qlik.com/t5/App-Development/Measure-Expression-Not-Limiting-To-Positives-In-Pivot-Table/m-p/1934447#M76976</link>
      <description>&lt;P&gt;I think I figured it out. The AGGR "group by" fields needed another field (one of the higher-level fields I was using as my pivot table row dimension). Once I added that higher-level field, the positive value criteria in the IF statement worked.&lt;/P&gt;</description>
      <pubDate>Mon, 23 May 2022 19:34:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Measure-Expression-Not-Limiting-To-Positives-In-Pivot-Table/m-p/1934447#M76976</guid>
      <dc:creator>newuser</dc:creator>
      <dc:date>2022-05-23T19:34:39Z</dc:date>
    </item>
  </channel>
</rss>

