<?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: Field Values to several Fields in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Field-Values-to-several-Fields/m-p/1721376#M506034</link>
    <description>&lt;P&gt;One Solution with Generic Load&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;DATA:
 
LOAD * INLINE [
    subject, test, result
    a, test1, ok
    a, test2, ok
    a, test3, nok
    b, test1, nok
    b, test2, ok
    b, test3, nok
];
CombinedGenericTable:

Load distinct subject resident DATA;

Tmp:
generic load * resident DATA;

drop table DATA;

FOR i = NoOfTables()-1 to 0 STEP -1

  LET vTable=TableName($(i));
  //trace $(i) - '$(vTable)';
  IF WildMatch('$(vTable)', 'Tmp.*') THEN 

  LEFT JOIN ([CombinedGenericTable]) LOAD distinct * RESIDENT [$(vTable)];

  DROP TABLE [$(vTable)];

  ENDIF 

NEXT i&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;output :&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Taoufiq_ZARRA_0-1592932532848.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/36114i1564EFB34BEF818F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Taoufiq_ZARRA_0-1592932532848.png" alt="Taoufiq_ZARRA_0-1592932532848.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 23 Jun 2020 17:15:55 GMT</pubDate>
    <dc:creator>Taoufiq_Zarra</dc:creator>
    <dc:date>2020-06-23T17:15:55Z</dc:date>
    <item>
      <title>Field Values to several Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Field-Values-to-several-Fields/m-p/1721367#M506033</link>
      <description>&lt;P&gt;Hi there.&lt;/P&gt;&lt;P&gt;I've been search the Qlik Community, but I cannot seem to find what I want, and probably it's just a matter of choosing the correct keys words. Anyway here goes.&lt;/P&gt;&lt;P&gt;I have a table with subject, test and result, for example:&lt;/P&gt;&lt;TABLE border="1" width="200"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="59.6667px" height="25px"&gt;subject&lt;/TD&gt;&lt;TD width="43.85px" height="25px"&gt;test&lt;/TD&gt;&lt;TD width="49.2px" height="25px"&gt;result&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="59.6667px" height="25px"&gt;a&lt;/TD&gt;&lt;TD width="43.85px" height="25px"&gt;test1&lt;/TD&gt;&lt;TD width="49.2px" height="25px"&gt;ok&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="59.6667px" height="25px"&gt;a&lt;/TD&gt;&lt;TD width="43.85px" height="25px"&gt;test2&lt;/TD&gt;&lt;TD width="49.2px" height="25px"&gt;ok&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="59.6667px" height="25px"&gt;a&lt;/TD&gt;&lt;TD width="43.85px" height="25px"&gt;test3&lt;/TD&gt;&lt;TD width="49.2px" height="25px"&gt;nok&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="59.6667px" height="25px"&gt;b&lt;/TD&gt;&lt;TD width="43.85px" height="25px"&gt;test1&lt;/TD&gt;&lt;TD width="49.2px" height="25px"&gt;nok&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="59.6667px" height="25px"&gt;b&lt;/TD&gt;&lt;TD width="43.85px" height="25px"&gt;test2&lt;/TD&gt;&lt;TD width="49.2px" height="25px"&gt;ok&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="59.6667px" height="25px"&gt;b&lt;/TD&gt;&lt;TD width="43.85px" height="25px"&gt;test3&lt;/TD&gt;&lt;TD width="49.2px" height="25px"&gt;nok&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And I want to show for each type of test (values from field test) the corresponding result (ok/nok) according to subject, so something like this:&lt;/P&gt;&lt;TABLE border="1" width="200"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="59.6667px"&gt;subject&lt;/TD&gt;&lt;TD width="43.85px"&gt;test1&lt;/TD&gt;&lt;TD width="43.85px"&gt;test2&lt;/TD&gt;&lt;TD width="43.85px"&gt;test3&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="59.6667px"&gt;a&lt;/TD&gt;&lt;TD width="43.85px"&gt;ok&lt;/TD&gt;&lt;TD width="43.85px"&gt;ok&lt;/TD&gt;&lt;TD width="43.85px"&gt;nok&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="59.6667px"&gt;b&lt;/TD&gt;&lt;TD width="43.85px"&gt;nok&lt;/TD&gt;&lt;TD width="43.85px"&gt;ok&lt;/TD&gt;&lt;TD width="43.85px"&gt;nok&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The closest I've been is with pivot table, but cannot seem to workout the expression to fit the needs (just don't know).&lt;/P&gt;&lt;P&gt;I believe this should be pretty straight forward, or? Any help?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Bruno Santos&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jun 2020 16:38:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Field-Values-to-several-Fields/m-p/1721367#M506033</guid>
      <dc:creator>brunosantos</dc:creator>
      <dc:date>2020-06-23T16:38:27Z</dc:date>
    </item>
    <item>
      <title>Re: Field Values to several Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Field-Values-to-several-Fields/m-p/1721376#M506034</link>
      <description>&lt;P&gt;One Solution with Generic Load&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;DATA:
 
LOAD * INLINE [
    subject, test, result
    a, test1, ok
    a, test2, ok
    a, test3, nok
    b, test1, nok
    b, test2, ok
    b, test3, nok
];
CombinedGenericTable:

Load distinct subject resident DATA;

Tmp:
generic load * resident DATA;

drop table DATA;

FOR i = NoOfTables()-1 to 0 STEP -1

  LET vTable=TableName($(i));
  //trace $(i) - '$(vTable)';
  IF WildMatch('$(vTable)', 'Tmp.*') THEN 

  LEFT JOIN ([CombinedGenericTable]) LOAD distinct * RESIDENT [$(vTable)];

  DROP TABLE [$(vTable)];

  ENDIF 

NEXT i&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;output :&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Taoufiq_ZARRA_0-1592932532848.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/36114i1564EFB34BEF818F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Taoufiq_ZARRA_0-1592932532848.png" alt="Taoufiq_ZARRA_0-1592932532848.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jun 2020 17:15:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Field-Values-to-several-Fields/m-p/1721376#M506034</guid>
      <dc:creator>Taoufiq_Zarra</dc:creator>
      <dc:date>2020-06-23T17:15:55Z</dc:date>
    </item>
    <item>
      <title>Re: Field Values to several Fields</title>
      <link>https://community.qlik.com/t5/QlikView/Field-Values-to-several-Fields/m-p/1722056#M506035</link>
      <description>&lt;P&gt;Thank you &lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/56648"&gt;@Taoufiq_Zarra&lt;/a&gt;&amp;nbsp;. That is exactly what I need.&lt;/P&gt;&lt;P&gt;And searching a little about Generic Load I've found this &lt;A href="https://community.qlik.com/t5/Qlik-Design-Blog/The-Generic-Load/ba-p/1473470" target="_blank" rel="noopener"&gt;post&lt;/A&gt; from &lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/6622"&gt;@hic&lt;/a&gt; with further explanation.&lt;/P&gt;&lt;P&gt;Once again thanks.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Bruno Santos&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jun 2020 09:15:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Field-Values-to-several-Fields/m-p/1722056#M506035</guid>
      <dc:creator>brunosantos</dc:creator>
      <dc:date>2020-06-25T09:15:13Z</dc:date>
    </item>
  </channel>
</rss>

