<?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: Join and calculate on Multiple Excel Sheets in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Join-and-calculate-on-Multiple-Excel-Sheets/m-p/1560473#M456970</link>
    <description>&lt;P&gt;&lt;SPAN&gt;Philipp,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;Yes you can but it&amp;nbsp;will be a little complicated procedure. First, find the number of Unique Namae and the number of loads per attribute. Finally, create a table with calculating using them.&lt;/P&gt;
&lt;P&gt;Tabelle1:&lt;BR /&gt;Load&lt;BR /&gt;Namae,&lt;BR /&gt;Attribute&lt;BR /&gt;FROM [lib://downloads/Demo.xlsx]&lt;BR /&gt;(ooxml, embedded labels, table is Tabelle1);&lt;/P&gt;
&lt;P&gt;//How many Unique Namae as max Rowno&lt;BR /&gt;Count1:&lt;BR /&gt;Load&lt;BR /&gt;RowNo() as No,&lt;BR /&gt;Namae,&lt;BR /&gt;count(Namae) as dummy&lt;BR /&gt;Resident Tabelle1 group by Namae;&lt;/P&gt;
&lt;P&gt;Let vNamaeCount = Num(Peek('No', -1, 'Count1')); //Set the last No of Count1 to vNameCount&lt;BR /&gt;&lt;BR /&gt;//How many times each attribute is attached&lt;BR /&gt;Count2:&lt;BR /&gt;Load&lt;BR /&gt;Attribute,&lt;BR /&gt;count(Attribute) as AttrCount&lt;BR /&gt;Resident Tabelle1 group by Attribute;&lt;/P&gt;
&lt;P&gt;//Make a table with calculations&lt;BR /&gt;Tabelle2:&lt;BR /&gt;LOAD&lt;BR /&gt;Attributes as Attribute&lt;BR /&gt;FROM [lib://downloads/Demo.xlsx]&lt;BR /&gt;(ooxml, embedded labels, table is Tabelle2);&lt;/P&gt;
&lt;P&gt;outer join (Tabelle2) LOAD&lt;BR /&gt;Attribute,&lt;BR /&gt;AttrCount,&lt;BR /&gt;AttrCount / $(vNamaeCount) as Distribution&lt;BR /&gt;Resident Count2;&lt;/P&gt;
&lt;P&gt;//Delete unnecessary tables&lt;BR /&gt;drop tables Count1, Count2;&lt;/P&gt;
&lt;P&gt;&lt;SPAN class="answer"&gt;I hope this will help.&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 25 Mar 2019 02:47:09 GMT</pubDate>
    <dc:creator>Yuki_Suzuki</dc:creator>
    <dc:date>2019-03-25T02:47:09Z</dc:date>
    <item>
      <title>Join and calculate on Multiple Excel Sheets</title>
      <link>https://community.qlik.com/t5/QlikView/Join-and-calculate-on-Multiple-Excel-Sheets/m-p/1556855#M456967</link>
      <description>&lt;P&gt;Dear all,&lt;/P&gt;&lt;P&gt;I have an Excel File with two sheets.&lt;/P&gt;&lt;P&gt;Sheet1 contains person names and attributes (a person can have 0-n attributes)&lt;/P&gt;&lt;TABLE cellspacing="0" cellpadding="0" border="0"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Name&lt;/TD&gt;&lt;TD&gt;Attribute&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Marc&lt;/TD&gt;&lt;TD&gt;male&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Marc&lt;/TD&gt;&lt;TD&gt;blond&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Jenny&lt;/TD&gt;&lt;TD&gt;female&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;John&lt;/TD&gt;&lt;TD&gt;blond&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Alex&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Jeff&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;Sheet2 contains all available attributes:&lt;/P&gt;&lt;TABLE cellspacing="0" cellpadding="0" border="0"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Attributes&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;male&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;female&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;blond&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;red&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I now want to create a table that tells me the attribute distribution. If the attribute is not named for a person, it can be assumed that the person does not have it. The result should look like this:&lt;/P&gt;&lt;TABLE cellspacing="0" cellpadding="0" border="0"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Attribute&lt;/TD&gt;&lt;TD&gt;Distribution&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;male&lt;/TD&gt;&lt;TD&gt;0.2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;female&lt;/TD&gt;&lt;TD&gt;0.2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;blond&lt;/TD&gt;&lt;TD&gt;0.4&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;red&lt;/TD&gt;&lt;TD&gt;0&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I already tried a lot with joins and count(total Name) etc., but just can't get it right. Could somebody help me with it?&lt;/P&gt;&lt;P&gt;Thanks a lot&lt;/P&gt;&lt;P&gt;Philipp&lt;/P&gt;</description>
      <pubDate>Thu, 14 Mar 2019 22:55:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-and-calculate-on-Multiple-Excel-Sheets/m-p/1556855#M456967</guid>
      <dc:creator>daumkep</dc:creator>
      <dc:date>2019-03-14T22:55:27Z</dc:date>
    </item>
    <item>
      <title>Re: Join and calculate on Multiple Excel Sheets</title>
      <link>https://community.qlik.com/t5/QlikView/Join-and-calculate-on-Multiple-Excel-Sheets/m-p/1556858#M456968</link>
      <description>&lt;P&gt;How about this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Load script&lt;/P&gt;
&lt;P&gt;LOAD&lt;BR /&gt;Namae,&lt;BR /&gt;"Attribute"&lt;BR /&gt;FROM [lib://????/Demo.xlsx]&lt;BR /&gt;(ooxml, embedded labels, table is Tabelle1);&lt;/P&gt;
&lt;P&gt;LOAD&lt;BR /&gt;Attributes as "Attribute"&lt;BR /&gt;FROM [lib://????/Demo.xlsx]&lt;BR /&gt;(ooxml, embedded labels, table is Tabelle2);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then make a table as below.&lt;/P&gt;
&lt;P&gt;Dimension : Attribute&lt;/P&gt;
&lt;P&gt;Measure:&amp;nbsp;count(distinct Namae)/count(distinct total Namae)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 15 Mar 2019 00:23:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-and-calculate-on-Multiple-Excel-Sheets/m-p/1556858#M456968</guid>
      <dc:creator>Yuki_Suzuki</dc:creator>
      <dc:date>2019-03-15T00:23:03Z</dc:date>
    </item>
    <item>
      <title>Re: Join and calculate on Multiple Excel Sheets</title>
      <link>https://community.qlik.com/t5/QlikView/Join-and-calculate-on-Multiple-Excel-Sheets/m-p/1560121#M456969</link>
      <description>&lt;P&gt;Dear Yuz,&lt;/P&gt;&lt;P&gt;thanks a lot for this option. Is there also a chance to calculate the proposed table within the Load Script?&lt;/P&gt;&lt;P&gt;Thanks a lot&lt;/P&gt;&lt;P&gt;Philipp&lt;/P&gt;</description>
      <pubDate>Fri, 22 Mar 2019 13:55:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-and-calculate-on-Multiple-Excel-Sheets/m-p/1560121#M456969</guid>
      <dc:creator>daumkep</dc:creator>
      <dc:date>2019-03-22T13:55:20Z</dc:date>
    </item>
    <item>
      <title>Re: Join and calculate on Multiple Excel Sheets</title>
      <link>https://community.qlik.com/t5/QlikView/Join-and-calculate-on-Multiple-Excel-Sheets/m-p/1560473#M456970</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Philipp,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;Yes you can but it&amp;nbsp;will be a little complicated procedure. First, find the number of Unique Namae and the number of loads per attribute. Finally, create a table with calculating using them.&lt;/P&gt;
&lt;P&gt;Tabelle1:&lt;BR /&gt;Load&lt;BR /&gt;Namae,&lt;BR /&gt;Attribute&lt;BR /&gt;FROM [lib://downloads/Demo.xlsx]&lt;BR /&gt;(ooxml, embedded labels, table is Tabelle1);&lt;/P&gt;
&lt;P&gt;//How many Unique Namae as max Rowno&lt;BR /&gt;Count1:&lt;BR /&gt;Load&lt;BR /&gt;RowNo() as No,&lt;BR /&gt;Namae,&lt;BR /&gt;count(Namae) as dummy&lt;BR /&gt;Resident Tabelle1 group by Namae;&lt;/P&gt;
&lt;P&gt;Let vNamaeCount = Num(Peek('No', -1, 'Count1')); //Set the last No of Count1 to vNameCount&lt;BR /&gt;&lt;BR /&gt;//How many times each attribute is attached&lt;BR /&gt;Count2:&lt;BR /&gt;Load&lt;BR /&gt;Attribute,&lt;BR /&gt;count(Attribute) as AttrCount&lt;BR /&gt;Resident Tabelle1 group by Attribute;&lt;/P&gt;
&lt;P&gt;//Make a table with calculations&lt;BR /&gt;Tabelle2:&lt;BR /&gt;LOAD&lt;BR /&gt;Attributes as Attribute&lt;BR /&gt;FROM [lib://downloads/Demo.xlsx]&lt;BR /&gt;(ooxml, embedded labels, table is Tabelle2);&lt;/P&gt;
&lt;P&gt;outer join (Tabelle2) LOAD&lt;BR /&gt;Attribute,&lt;BR /&gt;AttrCount,&lt;BR /&gt;AttrCount / $(vNamaeCount) as Distribution&lt;BR /&gt;Resident Count2;&lt;/P&gt;
&lt;P&gt;//Delete unnecessary tables&lt;BR /&gt;drop tables Count1, Count2;&lt;/P&gt;
&lt;P&gt;&lt;SPAN class="answer"&gt;I hope this will help.&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Mar 2019 02:47:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-and-calculate-on-Multiple-Excel-Sheets/m-p/1560473#M456970</guid>
      <dc:creator>Yuki_Suzuki</dc:creator>
      <dc:date>2019-03-25T02:47:09Z</dc:date>
    </item>
  </channel>
</rss>

