<?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 Linking 2 Alternate States in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Linking-2-Alternate-States/m-p/1817670#M66982</link>
    <description>&lt;P&gt;I have a fact table representing 'entities' .&lt;BR /&gt;Joined to that, many attribute tables.&lt;BR /&gt;&lt;BR /&gt;Now I want to include a parent-child relationship table for the entities.&lt;/P&gt;&lt;P&gt;Effectively, the user should be bale to select Parent entity 'A' and see all of it's attributes,&amp;nbsp;&lt;BR /&gt;then also see all A's children entities and their attributes.&lt;BR /&gt;&lt;BR /&gt;So I am wondering how best&amp;nbsp; to duplicate all my entities, so that I have a Parent set, and a Child set.&lt;BR /&gt;Link the 2 sets with the relationship map table.&lt;BR /&gt;&lt;BR /&gt;First thought was to duplicate all the tables in the load editor.&lt;BR /&gt;Then I was drawn to 'Alternate States' ... but struggling to understand how I could link State 'parent' to State 'child' ?&lt;/P&gt;&lt;P&gt;I got thus far :&amp;nbsp;&lt;/P&gt;&lt;P&gt;Crated a table with Dimension&amp;nbsp; 'entity_name'&lt;BR /&gt;Then measure :&amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;=count( {&amp;lt;entity_id=$::child_entity_nid&amp;gt;} 1)&lt;BR /&gt;&lt;BR /&gt;This works ONLY if I explicitly select&amp;nbsp;&amp;nbsp;[child_entity_nid]&amp;nbsp; values ... but not if implicit.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Appreciate any pointers,&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;BR /&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 24 Jun 2021 17:39:43 GMT</pubDate>
    <dc:creator>simonB2020</dc:creator>
    <dc:date>2021-06-24T17:39:43Z</dc:date>
    <item>
      <title>Linking 2 Alternate States</title>
      <link>https://community.qlik.com/t5/App-Development/Linking-2-Alternate-States/m-p/1817670#M66982</link>
      <description>&lt;P&gt;I have a fact table representing 'entities' .&lt;BR /&gt;Joined to that, many attribute tables.&lt;BR /&gt;&lt;BR /&gt;Now I want to include a parent-child relationship table for the entities.&lt;/P&gt;&lt;P&gt;Effectively, the user should be bale to select Parent entity 'A' and see all of it's attributes,&amp;nbsp;&lt;BR /&gt;then also see all A's children entities and their attributes.&lt;BR /&gt;&lt;BR /&gt;So I am wondering how best&amp;nbsp; to duplicate all my entities, so that I have a Parent set, and a Child set.&lt;BR /&gt;Link the 2 sets with the relationship map table.&lt;BR /&gt;&lt;BR /&gt;First thought was to duplicate all the tables in the load editor.&lt;BR /&gt;Then I was drawn to 'Alternate States' ... but struggling to understand how I could link State 'parent' to State 'child' ?&lt;/P&gt;&lt;P&gt;I got thus far :&amp;nbsp;&lt;/P&gt;&lt;P&gt;Crated a table with Dimension&amp;nbsp; 'entity_name'&lt;BR /&gt;Then measure :&amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;=count( {&amp;lt;entity_id=$::child_entity_nid&amp;gt;} 1)&lt;BR /&gt;&lt;BR /&gt;This works ONLY if I explicitly select&amp;nbsp;&amp;nbsp;[child_entity_nid]&amp;nbsp; values ... but not if implicit.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Appreciate any pointers,&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;BR /&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Jun 2021 17:39:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Linking-2-Alternate-States/m-p/1817670#M66982</guid>
      <dc:creator>simonB2020</dc:creator>
      <dc:date>2021-06-24T17:39:43Z</dc:date>
    </item>
    <item>
      <title>Re: Linking 2 Alternate States</title>
      <link>https://community.qlik.com/t5/App-Development/Linking-2-Alternate-States/m-p/1817702#M66984</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Instead of alternate states have you looked at using P() function? So using toy app script below I think this shows the kind of effect you are looking for;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="20210624_1.png" style="width: 967px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/57495iD601F3F4BC0A6562/image-size/large?v=v2&amp;amp;px=999" role="button" title="20210624_1.png" alt="20210624_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Chris.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;parentchild:
Load * inline [
Parent, Child
, A
A, B
A, C
, D
D, E
];

staticdata:
load * Inline [
Child, Attribute
A, 1
B, 2
C, 3
D, 4
E, 5
];&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Jun 2021 18:22:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Linking-2-Alternate-States/m-p/1817702#M66984</guid>
      <dc:creator>chrismarlow</dc:creator>
      <dc:date>2021-06-24T18:22:49Z</dc:date>
    </item>
  </channel>
</rss>

