Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Data joining in QlikView

Hi All

I am facing data joining issue.Initially my data has two tables as below:

QlikImage.PNG

I used applymap for Region and country columns so as to get full names,but still I am getting table as above.I need something which looks like:

Qlikimage2.PNG

Please help me.....

1 Solution

Accepted Solutions
vinieme12
Champion III
Champion III

FACT:

LOAD Region,

     Country,

     City,

     SiteID,

     AccountNumber,

     Model,

     Desc,

     Amount

FROM

(ooxml, embedded labels, table is Sheet1);

JOIN

LOAD

     AccountNumber,

     BillingNum,

     Sale

FROM

(ooxml, embedded labels, table is Sheet2);

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.

View solution in original post

20 Replies
sdmech81
Specialist
Specialist

Hi if u are expecting common data plss do inner join like

Table 1

Inner join

Table 2..

But do note that the join I'd should be Site ID and other than that make sure that u alias rest of the other column .

If table 1 is main table then use left join in btn..Don't keep column names same in both tables same..And comment out unwanted columns like u don't want region n country frm table 2 then comment them out.

Sachin

vishsaggi
Champion III
Champion III

Do you have an excel sheet data that depicts what you have in that image to work on it ? Please attach if possible?

Anonymous
Not applicable
Author

Hi Sachin

I need fields from both tables,otherwise I am not getting respective SALE value if I don't use fields in second table,here AS and ASIA are of same data but are differing in names,

sdmech81
Specialist
Specialist

Then atleast rename them and join else ur joining 2 tables with key which includes all multiple columns..

It will lead to wrong result..U join based on siteId only..Rest fields in tble 2 rename as per ur wish..

Anonymous
Not applicable
Author

Check the attached qvw.

I hope you find it helpfull

vinieme12
Champion III
Champion III

You don't need applymap here!Just Left join both the tables......you already have full country,region and city names in table1 so use the same

Table1:

Region,

country,

city,

AccountNumber,

Model,

desc,

Amount,

SiteID,

SiteID&'_'&AccountNumber as KEY

FromTable_1_SRC;

left join

Table2:

BillingNumber,

Sale,

SiteID&'_'&AccountNumber as KEY

FromTable_2_SRC;

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
Anonymous
Not applicable
Author

Hi Sachin/Vineeth

Got upto an extent

but my data have two rows in first table and second table have more rows as shownQlikimage3.PNGQlikimage4.PNG

but my data is showing like

Qlikimage5.PNG

hope u understood my problem now.

sdmech81
Specialist
Specialist

Hi,

As per initial table images,

Please try using key I.e combination of site I'd and acct no..

Please read this thread for understanding

Understanding Join, Keep and Concatenate

Anonymous
Not applicable
Author

Hi

I used account number as key,as I can't use combination of both.But,data which have more columns with same Account number are not showing values.It should be like:Qlikimage6.PNG

I don't understand why these values are missing if there are more rows