<?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: Joining two tables with same fields in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Joining-two-tables-with-same-fields/m-p/1881177#M72608</link>
    <description>&lt;P&gt;HI&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/56648"&gt;@Taoufiq_Zarra&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I made some modifications to the above code. Now the addr,city,country is available in the database but it is not reflecting in qliksense.'&lt;/P&gt;
&lt;P&gt;The changes I perferomed is,&lt;/P&gt;
&lt;P&gt;I wrote a mapping load&amp;nbsp; and tried to use apply map to get the details.&amp;nbsp; I can see the data is available in the raw file but in qliksense I am getting NULL values.&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="python"&gt;MapTable:
Mapping Load 
EmpNo,City
from abc.xlsx;

Tabl1:

Load 

EmpNo,

EmpName,

Applymap('MapTable',EmpNo,'NA') as City,

Country,

Address

from abc.qvd;

left join

Load 

EmpNo

EmpCity,

EmpAddr,

EmpCountry,

EmpSalary

from xyz.qvd;

Final:
noconcatenate

load EmpNo, EmpName, if(len(trim(City))=0,EmpCity,City) as  City,if(len(trim(Country))=0,EmpCountry,Country) as  Country , if(len(trim(Address))=0,EmpAddr,Address) as Address,  EmpSalary resident Tabl1;

drop table Tabl1;&lt;/LI-CODE&gt;
&lt;P&gt;Thanks in advance!!&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 14 Jan 2022 14:50:02 GMT</pubDate>
    <dc:creator>qlikuser22</dc:creator>
    <dc:date>2022-01-14T14:50:02Z</dc:date>
    <item>
      <title>Joining two tables with same fields</title>
      <link>https://community.qlik.com/t5/App-Development/Joining-two-tables-with-same-fields/m-p/1880663#M72574</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;
&lt;P&gt;I am struck with a problem where I have two tables and want to extract the data and final result in one table.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Tabl1:&lt;/P&gt;
&lt;P&gt;Load&amp;nbsp;&lt;/P&gt;
&lt;P&gt;EmpNo,&lt;/P&gt;
&lt;P&gt;EmpName,&lt;/P&gt;
&lt;P&gt;City,&lt;/P&gt;
&lt;P&gt;Country,&lt;/P&gt;
&lt;P&gt;Address&lt;/P&gt;
&lt;P&gt;from abc.qvd;&lt;/P&gt;
&lt;P&gt;Tabl2:&lt;/P&gt;
&lt;P&gt;Load&amp;nbsp;&lt;/P&gt;
&lt;P&gt;EmpNo&lt;/P&gt;
&lt;P&gt;EmpCity,&lt;/P&gt;
&lt;P&gt;EmpAddr,&lt;/P&gt;
&lt;P&gt;EmpCountry,&lt;/P&gt;
&lt;P&gt;EmpSalary&lt;/P&gt;
&lt;P&gt;from xyz.qvd;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need to do something like, For each employee number , I want to produce the address, city and country. If the details are not available I have to pick the address, city and country from table2.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The final table should be,&lt;/P&gt;
&lt;P&gt;EmpNo, EmpName, City,Country,Address, EmpSalary&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks.&lt;/P&gt;
&lt;P&gt;Please do help.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 13 Jan 2022 12:18:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Joining-two-tables-with-same-fields/m-p/1880663#M72574</guid>
      <dc:creator>qlikuser22</dc:creator>
      <dc:date>2022-01-13T12:18:51Z</dc:date>
    </item>
    <item>
      <title>Re: Joining two tables with same fields</title>
      <link>https://community.qlik.com/t5/App-Development/Joining-two-tables-with-same-fields/m-p/1880682#M72578</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/138474"&gt;@qlikuser22&lt;/a&gt;&amp;nbsp; you can for example use :&lt;/P&gt;
&lt;LI-CODE lang="python"&gt;Tabl1:

Load 

EmpNo,

EmpName,

City,

Country,

Address

from abc.qvd;

left join

Load 

EmpNo

EmpCity,

EmpAddr,

EmpCountry,

EmpSalary

from xyz.qvd;

Final:
noconcatenate

load EmpNo, EmpName, if(len(trim(City))=0,EmpCity,City) as  City,if(len(trim(Country))=0,EmpCountry,Country) as  Country , if(len(trim(Address))=0,EmpAddr,Address) as Address,  EmpSalary resident Tabl1;

drop table Tabl1;&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 13 Jan 2022 13:11:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Joining-two-tables-with-same-fields/m-p/1880682#M72578</guid>
      <dc:creator>Taoufiq_Zarra</dc:creator>
      <dc:date>2022-01-13T13:11:24Z</dc:date>
    </item>
    <item>
      <title>Re: Joining two tables with same fields</title>
      <link>https://community.qlik.com/t5/App-Development/Joining-two-tables-with-same-fields/m-p/1880712#M72581</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/56648"&gt;@Taoufiq_Zarra&lt;/a&gt;&amp;nbsp; It worked perfectly. I was struggling a lot in this. There is so much to learn. Thanks a lot &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 13 Jan 2022 14:18:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Joining-two-tables-with-same-fields/m-p/1880712#M72581</guid>
      <dc:creator>qlikuser22</dc:creator>
      <dc:date>2022-01-13T14:18:21Z</dc:date>
    </item>
    <item>
      <title>Re: Joining two tables with same fields</title>
      <link>https://community.qlik.com/t5/App-Development/Joining-two-tables-with-same-fields/m-p/1881177#M72608</link>
      <description>&lt;P&gt;HI&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/56648"&gt;@Taoufiq_Zarra&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I made some modifications to the above code. Now the addr,city,country is available in the database but it is not reflecting in qliksense.'&lt;/P&gt;
&lt;P&gt;The changes I perferomed is,&lt;/P&gt;
&lt;P&gt;I wrote a mapping load&amp;nbsp; and tried to use apply map to get the details.&amp;nbsp; I can see the data is available in the raw file but in qliksense I am getting NULL values.&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="python"&gt;MapTable:
Mapping Load 
EmpNo,City
from abc.xlsx;

Tabl1:

Load 

EmpNo,

EmpName,

Applymap('MapTable',EmpNo,'NA') as City,

Country,

Address

from abc.qvd;

left join

Load 

EmpNo

EmpCity,

EmpAddr,

EmpCountry,

EmpSalary

from xyz.qvd;

Final:
noconcatenate

load EmpNo, EmpName, if(len(trim(City))=0,EmpCity,City) as  City,if(len(trim(Country))=0,EmpCountry,Country) as  Country , if(len(trim(Address))=0,EmpAddr,Address) as Address,  EmpSalary resident Tabl1;

drop table Tabl1;&lt;/LI-CODE&gt;
&lt;P&gt;Thanks in advance!!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Jan 2022 14:50:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Joining-two-tables-with-same-fields/m-p/1881177#M72608</guid>
      <dc:creator>qlikuser22</dc:creator>
      <dc:date>2022-01-14T14:50:02Z</dc:date>
    </item>
  </channel>
</rss>

