<?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: Multiple alternate states as a synthetic dimension in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Multiple-alternate-states-as-a-synthetic-dimension/m-p/1601814#M63184</link>
    <description>&lt;P&gt;I'm not really sure if I understand your approach right but I assume that you want to refer with:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;$(mMeasure1(SyntheticDimensionValue))&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;to the dimensionsvalues of:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;$(mMeasure1(State1))&lt;BR /&gt;$(mMeasure1(State2))&lt;BR /&gt;...&lt;BR /&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;If so it won't work because a $-sign expansion will be executed first and the result of it is then applied to all chart-calculations.&lt;/P&gt;&lt;P&gt;The only way to get such a construct to work is the following:&lt;/P&gt;&lt;P&gt;pick(match(SyntheticDim, 'default', 'state1', 'state2'),&lt;BR /&gt;&amp;nbsp;&amp;nbsp; expr1, expr2, exp3)&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;</description>
    <pubDate>Fri, 12 Jul 2019 12:03:05 GMT</pubDate>
    <dc:creator>marcus_sommer</dc:creator>
    <dc:date>2019-07-12T12:03:05Z</dc:date>
    <item>
      <title>Multiple alternate states as a synthetic dimension</title>
      <link>https://community.qlik.com/t5/App-Development/Multiple-alternate-states-as-a-synthetic-dimension/m-p/1601578#M63183</link>
      <description>&lt;P&gt;Hello, has anyone ever attempted to use multiple alternate states as a dimension, e.g. in a pivot table?&lt;/P&gt;&lt;P&gt;For example, suppose I have three alternate states,&amp;nbsp;and I would like to construct a pivot table with measures along the rows such that each column would contain data for a the corresponding alternate state:&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;lt;default&amp;gt;&lt;/TD&gt;&lt;TD&gt;&amp;lt;state1&amp;gt;&lt;/TD&gt;&lt;TD&gt;&amp;lt;state2&amp;gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;measure1&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;measure 2&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;...&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The easiest way to do this would be to construct a synthetic dimension composed of the alternate states and then let Qlik do its magic, but I haven't figured out how to get this to work.&lt;/P&gt;&lt;P&gt;One thing I *have* attempted is to create a synthetic dimension via inline load containing the names of the alternate states as strings, and then to write each measure as a paramatized variable, where the value of the synthetic dimension would be read in as a set identifier, like this:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Set mMeasure1 = Sum({$1}MyField)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;and then set the pivot table measure equal to:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;$(mMeasure1(SyntheticDimensionValue))&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;...but I haven't gotten this to work either. Tried lots of permutations of dollar sign expansions too.&lt;/P&gt;&lt;P&gt;Ideas??? Much gratitude for any help!&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 05:18:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Multiple-alternate-states-as-a-synthetic-dimension/m-p/1601578#M63183</guid>
      <dc:creator>ArrogantAardvark</dc:creator>
      <dc:date>2024-11-16T05:18:30Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple alternate states as a synthetic dimension</title>
      <link>https://community.qlik.com/t5/App-Development/Multiple-alternate-states-as-a-synthetic-dimension/m-p/1601814#M63184</link>
      <description>&lt;P&gt;I'm not really sure if I understand your approach right but I assume that you want to refer with:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;$(mMeasure1(SyntheticDimensionValue))&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;to the dimensionsvalues of:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;$(mMeasure1(State1))&lt;BR /&gt;$(mMeasure1(State2))&lt;BR /&gt;...&lt;BR /&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;If so it won't work because a $-sign expansion will be executed first and the result of it is then applied to all chart-calculations.&lt;/P&gt;&lt;P&gt;The only way to get such a construct to work is the following:&lt;/P&gt;&lt;P&gt;pick(match(SyntheticDim, 'default', 'state1', 'state2'),&lt;BR /&gt;&amp;nbsp;&amp;nbsp; expr1, expr2, exp3)&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;</description>
      <pubDate>Fri, 12 Jul 2019 12:03:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Multiple-alternate-states-as-a-synthetic-dimension/m-p/1601814#M63184</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2019-07-12T12:03:05Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple alternate states as a synthetic dimension</title>
      <link>https://community.qlik.com/t5/App-Development/Multiple-alternate-states-as-a-synthetic-dimension/m-p/1601885#M63185</link>
      <description>&lt;P&gt;Spot on, that's exactly what I'm trying to do. Was hoping to avoid having to code the expression multiple times in a pick list, but I didn't stop to think that a $ expansion would be applied uniformly across a measure. Marking as solved, thanks for the expedient help.&lt;/P&gt;</description>
      <pubDate>Fri, 12 Jul 2019 14:46:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Multiple-alternate-states-as-a-synthetic-dimension/m-p/1601885#M63185</guid>
      <dc:creator>ArrogantAardvark</dc:creator>
      <dc:date>2019-07-12T14:46:04Z</dc:date>
    </item>
  </channel>
</rss>

