<?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: set expression to combine data from another row in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632745#M446573</link>
    <description>&lt;P&gt;sorry, I realize this is wrong track entirely. maybe the factor should just be a variable or something because it does break down into about 10 rules. like "add 50% of the float dollars for this day, in this facility to one department and then 25% to a different department..."&lt;/P&gt;</description>
    <pubDate>Tue, 08 Oct 2019 20:51:38 GMT</pubDate>
    <dc:creator>daveatkins</dc:creator>
    <dc:date>2019-10-08T20:51:38Z</dc:date>
    <item>
      <title>set expression to combine data from another row</title>
      <link>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632644#M446564</link>
      <description>&lt;P&gt;I have data which summarizes by facility and includes some values that are to be apportioned across the facilities. These are called "float dollars." So you might have&lt;/P&gt;&lt;P&gt;facility A, expense item X, $100&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;facility A, float dollars, $50&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;so the total for the facility might be:&lt;/P&gt;&lt;P&gt;facility A = DepartmentX sum of values + float = 100+50 = $150&lt;/P&gt;&lt;P&gt;I need to write a set expression that will be something like this, for the float component:&lt;/P&gt;&lt;P&gt;Sum( { &amp;lt;DepartmentType={'Float Dollars'} &amp;gt;} CalcTotal)&lt;/P&gt;&lt;P&gt;How do I get the expression to "reset" the DepartmentType so that this sum will be evaluated on the same line as DepartmentX?&lt;/P&gt;&lt;P&gt;In other words, the resulting table of data would look like this for Facility A:&lt;/P&gt;&lt;P&gt;Department, direct expense, float component, total expense&lt;/P&gt;&lt;P&gt;DepartmentX, 100, 50, 150&lt;/P&gt;&lt;P&gt;Float Dollars, 50,50, 100 (this is actually not meaningful sum, but that is what the data would display as if you just added the columns, because float is recorded in the data as another department. In the report, this department would be excluded from the dimension so as not to have this line appearing)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Oct 2019 16:13:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632644#M446564</guid>
      <dc:creator>daveatkins</dc:creator>
      <dc:date>2019-10-08T16:13:23Z</dc:date>
    </item>
    <item>
      <title>Re: set expression to combine data from another row</title>
      <link>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632655#M446565</link>
      <description>&lt;P&gt;What is DepartmentX here? Is it coming from a field in your data? Can you share a better sample?&lt;/P&gt;</description>
      <pubDate>Tue, 08 Oct 2019 16:57:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632655#M446565</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-10-08T16:57:14Z</dc:date>
    </item>
    <item>
      <title>Re: set expression to combine data from another row</title>
      <link>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632660#M446566</link>
      <description>&lt;P&gt;The "TOTAL" keyword is your friend here:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;&lt;SPAN&gt;Sum( { &amp;lt;DepartmentType={'Float Dollars'} &amp;gt;} &lt;STRONG&gt;TOTAL&lt;/STRONG&gt; CalcTotal)&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;-Rob&lt;BR /&gt;&lt;A href="http://masterssummit.com" target="_blank"&gt;http://masterssummit.com&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://qlikviewcookbook.com" target="_blank"&gt;http://qlikviewcookbook.com&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://www.easyqlik.com" target="_blank"&gt;http://www.easyqlik.com&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Oct 2019 17:02:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632660#M446566</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2019-10-08T17:02:45Z</dc:date>
    </item>
    <item>
      <title>Re: set expression to combine data from another row</title>
      <link>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632702#M446571</link>
      <description>&lt;P&gt;THANK YOU YES! I had forgotten how that worked; exactly what I was looking for&lt;/P&gt;</description>
      <pubDate>Tue, 08 Oct 2019 18:44:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632702#M446571</guid>
      <dc:creator>daveatkins</dc:creator>
      <dc:date>2019-10-08T18:44:05Z</dc:date>
    </item>
    <item>
      <title>Re: set expression to combine data from another row</title>
      <link>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632741#M446572</link>
      <description>&lt;P&gt;a slight complexity...so there is also a joined column containing&amp;nbsp; a factor...and I cannot get this expression to quite work:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sum( { &amp;lt;DepartmentType={'Float Dollars'} &amp;gt;} TOTAL &amp;lt;CorpDesc&amp;gt; (CalcTotalPay * FloatFactor) )&lt;/P&gt;&lt;P&gt;The following expression works, but fails to sum properly in the totals...i.e. it is correct in the pivot for each CorpDesc, but in the totals, it is not using the correct FloatFactor at the necessary row level of detail:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;=Sum(CalcTotalPay) + if(isnull(min(FloatFactor)),0,min(FloatFactor)) * Sum( { &amp;lt;DepartmentType={'Float Dollars'} &amp;gt;} TOTAL &amp;lt;CorpDesc&amp;gt; CalcTotalPay )&lt;/P&gt;</description>
      <pubDate>Tue, 08 Oct 2019 20:29:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632741#M446572</guid>
      <dc:creator>daveatkins</dc:creator>
      <dc:date>2019-10-08T20:29:18Z</dc:date>
    </item>
    <item>
      <title>Re: set expression to combine data from another row</title>
      <link>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632745#M446573</link>
      <description>&lt;P&gt;sorry, I realize this is wrong track entirely. maybe the factor should just be a variable or something because it does break down into about 10 rules. like "add 50% of the float dollars for this day, in this facility to one department and then 25% to a different department..."&lt;/P&gt;</description>
      <pubDate>Tue, 08 Oct 2019 20:51:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632745#M446573</guid>
      <dc:creator>daveatkins</dc:creator>
      <dc:date>2019-10-08T20:51:38Z</dc:date>
    </item>
    <item>
      <title>Re: set expression to combine data from another row</title>
      <link>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632753#M446574</link>
      <description>&lt;P&gt;You likely have a "sum of rows" problem that requires Aggr(). See if this explains it&amp;nbsp;&lt;A href="https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/ChartFunctions/NestedAggregations/sum-of-rows-pivot-tables.htm" target="_blank"&gt;https://help.qlik.com/en-US/qlikview/April2019/Subsystems/Client/Content/QV_QlikView/ChartFunctions/NestedAggregations/sum-of-rows-pivot-tables.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;-Rob&lt;/P&gt;</description>
      <pubDate>Tue, 08 Oct 2019 21:43:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/set-expression-to-combine-data-from-another-row/m-p/1632753#M446574</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2019-10-08T21:43:20Z</dc:date>
    </item>
  </channel>
</rss>

