<?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: Elements having root-parent element with certain attribute in Listbox in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134531#M372575</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Marvin,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you please post the example so that we can try to help you in resolving the issue and try to attach the output which you are looking for.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 20 Aug 2016 15:17:56 GMT</pubDate>
    <dc:creator>svinnakota</dc:creator>
    <dc:date>2016-08-20T15:17:56Z</dc:date>
    <item>
      <title>Elements having root-parent element with certain attribute in Listbox</title>
      <link>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134529#M372573</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi folks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I currently struggle with the following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a hierachical structure of elements. Each element has an attribute &lt;EM&gt;parentID&lt;/EM&gt; referring to its parent element and an attribute &lt;EM&gt;A&lt;/EM&gt; with possible values &lt;EM&gt;X&lt;/EM&gt;, &lt;EM&gt;Y&lt;/EM&gt;, &lt;EM&gt;Z&lt;/EM&gt;. Elements where the &lt;EM&gt;parentID&lt;/EM&gt; is null, are root elements.&lt;/P&gt;&lt;P&gt;What I want to do, is having a listbox in tree view (so far so good), which contains all r&lt;STRONG&gt;oot elements having &lt;EM&gt;A = X&lt;/EM&gt;&lt;/STRONG&gt; and &lt;STRONG&gt;all its children&lt;/STRONG&gt; &lt;STRONG&gt;regardless of their attribute &lt;EM&gt;A&lt;/EM&gt;'s value&lt;/STRONG&gt; (as sub elements in the tree view).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tried a couple of different set analyses but couldn't achieve the desired result...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help pointing me to a solution for my problem is highly appreciated!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Marvin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Aug 2016 16:44:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134529#M372573</guid>
      <dc:creator />
      <dc:date>2016-08-18T16:44:41Z</dc:date>
    </item>
    <item>
      <title>Re: Elements having root-parent element with certain attribute in Listbox</title>
      <link>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134530#M372574</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Please post a small qlikview document that illustrates the problem.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 20 Aug 2016 15:04:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134530#M372574</guid>
      <dc:creator>Gysbert_Wassenaar</dc:creator>
      <dc:date>2016-08-20T15:04:37Z</dc:date>
    </item>
    <item>
      <title>Re: Elements having root-parent element with certain attribute in Listbox</title>
      <link>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134531#M372575</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Marvin,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you please post the example so that we can try to help you in resolving the issue and try to attach the output which you are looking for.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 20 Aug 2016 15:17:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134531#M372575</guid>
      <dc:creator>svinnakota</dc:creator>
      <dc:date>2016-08-20T15:17:56Z</dc:date>
    </item>
    <item>
      <title>Re: Elements having root-parent element with certain attribute in Listbox</title>
      <link>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134532#M372576</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think you can use the HIERARCHY resp. HIERARCHYBELONGSTO LOAD prefixes to create a model that serves your need.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/docs/DOC-5334"&gt;Hierarchies&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Something like&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Set NULLINTERPRET = '';&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;INPUT:&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;LOAD *, If(Len(Trim(ParentID))=0 and AttributeA = 'A', 1) as Flag INLINE [&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;ParentID, NodeID, AttributeA, Name&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;, 1,A, Parent 1&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;1,2,B, A child&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;1,3,C, B child&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;2,4,A, C child&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;, 5, B, Another parent&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;5,6, A, D child&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;];&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Hierarchy(NodeID, PID, NodeName, Parent, NodeName, Path)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;LOAD ParentID as PID, NodeID, Name as NodeName&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;RESIDENT INPUT;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;HierarchyBelongsTo( NodeID, PID2, Name2, PID2, Ancestor)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;LOAD ParentID as PID2, NodeID, Name as Name2&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;RESIDENT INPUT;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Left JOIN &lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;LOAD NodeID as PID2, Flag as Flag2 RESIDENT INPUT;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then you can create your list box with the treeview style and filter using Flag2:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;=Aggr(Only({1&amp;lt;Flag2 = {1}&amp;gt;}Path), Path)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="2016-08-20 23_28_00-QlikView x64 - [C__Users_Stefan_Downloads_comm229627.qvw_].png" class="jive-image image-1" src="/legacyfs/online/135079_2016-08-20 23_28_00-QlikView x64 - [C__Users_Stefan_Downloads_comm229627.qvw_].png" style="height: 247px; width: 620px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 20 Aug 2016 21:28:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134532#M372576</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2016-08-20T21:28:45Z</dc:date>
    </item>
    <item>
      <title>Re: Elements having root-parent element with certain attribute in Listbox</title>
      <link>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134533#M372577</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks, Stefan! &lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;Works perfectly fine!&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 23 Aug 2016 00:49:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Elements-having-root-parent-element-with-certain-attribute-in/m-p/1134533#M372577</guid>
      <dc:creator />
      <dc:date>2016-08-23T00:49:30Z</dc:date>
    </item>
  </channel>
</rss>

