<?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 Reference Column in Pivot for %  in rest of Pivot? in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Reference-Column-in-Pivot-for-in-rest-of-Pivot/m-p/2523196#M106750</link>
    <description>&lt;P&gt;As usual , a picture is probably the easiest way to explain.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Simply put, we have a year ( 2018 - in green ) where we have some sales figures , we'd like to compare to other years.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The bottom left table is the set analysis that is failing, using code :&lt;/P&gt;&lt;P&gt;(Sum(ExSales)/&lt;BR /&gt;Sum({&amp;lt;ExYear={"2018"}&amp;gt;}ExSales)&lt;BR /&gt;)&lt;BR /&gt;-1&lt;/P&gt;&lt;P&gt;It should look like the figures on the bottom right ( build using load script table )&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="110_0-1751627748574.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/181827iE3473BE0557DF6E9/image-size/large?v=v2&amp;amp;px=999" role="button" title="110_0-1751627748574.png" alt="110_0-1751627748574.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So, if I had access to the load script, I'd do something like this , and simply have a reference to the 2018 numbers for all sites, but sadly , I can't access the load script, so need to do the equivalent in the Chart/Table script at runtime.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;NoConcatenate&lt;/P&gt;&lt;P&gt;load&lt;BR /&gt;ExSite,&lt;BR /&gt;SUM(ExSales) as 'ExSalesFY18'&lt;/P&gt;&lt;P&gt;resident ExampleData&lt;/P&gt;&lt;P&gt;where ExYear =2018&lt;/P&gt;&lt;P&gt;group by ExSite;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 04 Jul 2025 11:18:41 GMT</pubDate>
    <dc:creator>110</dc:creator>
    <dc:date>2025-07-04T11:18:41Z</dc:date>
    <item>
      <title>Reference Column in Pivot for %  in rest of Pivot?</title>
      <link>https://community.qlik.com/t5/App-Development/Reference-Column-in-Pivot-for-in-rest-of-Pivot/m-p/2523196#M106750</link>
      <description>&lt;P&gt;As usual , a picture is probably the easiest way to explain.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Simply put, we have a year ( 2018 - in green ) where we have some sales figures , we'd like to compare to other years.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The bottom left table is the set analysis that is failing, using code :&lt;/P&gt;&lt;P&gt;(Sum(ExSales)/&lt;BR /&gt;Sum({&amp;lt;ExYear={"2018"}&amp;gt;}ExSales)&lt;BR /&gt;)&lt;BR /&gt;-1&lt;/P&gt;&lt;P&gt;It should look like the figures on the bottom right ( build using load script table )&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="110_0-1751627748574.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/181827iE3473BE0557DF6E9/image-size/large?v=v2&amp;amp;px=999" role="button" title="110_0-1751627748574.png" alt="110_0-1751627748574.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So, if I had access to the load script, I'd do something like this , and simply have a reference to the 2018 numbers for all sites, but sadly , I can't access the load script, so need to do the equivalent in the Chart/Table script at runtime.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;NoConcatenate&lt;/P&gt;&lt;P&gt;load&lt;BR /&gt;ExSite,&lt;BR /&gt;SUM(ExSales) as 'ExSalesFY18'&lt;/P&gt;&lt;P&gt;resident ExampleData&lt;/P&gt;&lt;P&gt;where ExYear =2018&lt;/P&gt;&lt;P&gt;group by ExSite;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 04 Jul 2025 11:18:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Reference-Column-in-Pivot-for-in-rest-of-Pivot/m-p/2523196#M106750</guid>
      <dc:creator>110</dc:creator>
      <dc:date>2025-07-04T11:18:41Z</dc:date>
    </item>
    <item>
      <title>Re: Reference Column in Pivot for %  in rest of Pivot?</title>
      <link>https://community.qlik.com/t5/App-Development/Reference-Column-in-Pivot-for-in-rest-of-Pivot/m-p/2523201#M106751</link>
      <description>&lt;P&gt;The problem is the year-dimension because the data from 2018 doesn't belong to another year and reverse. It has nothing to do with the selection state respectively the set analysis else the association between the data.&lt;/P&gt;&lt;P&gt;There are various ways to solve such challenge, for example:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;using interrecord-functions like above(), below(), before() and after() to access any cell within the chart&lt;/LI&gt;&lt;LI&gt;avoiding the "critical" dimension and using only expressions, like: sum({&amp;lt; Year = {X}&amp;gt;} Value) /&amp;nbsp;sum({&amp;lt; Year = {Y}&amp;gt;} Value)&lt;/LI&gt;&lt;LI&gt;implementing adjustments to the data-model, maybe with:&amp;nbsp;&lt;A href="https://community.qlik.com/t5/Design/The-As-Of-Table/ba-p/1466130" target="_blank"&gt;The As-Of Table - Qlik Community - 1466130&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 04 Jul 2025 11:46:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Reference-Column-in-Pivot-for-in-rest-of-Pivot/m-p/2523201#M106751</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2025-07-04T11:46:12Z</dc:date>
    </item>
  </channel>
</rss>

