Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
user8
Contributor III
Contributor III

Read data from two files and generate a single file

Hi,

I have two files and want to read specific columns and produce a single file based on the matching columns. For e.g.

--> File1

Emp NoEmp Name
123Steve
456Bryan

 

--> File2

Emp NoProduct
123Samsung
456Apple

 

--> File3 (Desired output)

Emp NoEmp NameProduct
123SteveSamsung
456BryanApple

 

Is this possible and can you share the script?

 

Thank you.

Labels (1)
4 Replies
ArjunChandra
Contributor II
Contributor II

If you find better answer please aslo share with me.

T1:
LOAD * INLINE [

Eno,EName
123,Steve
456,Bryan
];
Inner Join

LOAD * INLINE [

Eno,Product
123,Samsung
456,Apple
];
Try this

or

T1:
LOAD * inline [

Eno,Ename,Salary
123,Steve,55000
456,BRYAN,90000
];

T2:
LOAD * inline [

Eno,Product,UnitCost
123,Samsung,20000
456,Apple,60000
];

Temp:
LOAD Eno,Ename Resident T1;
Inner Join
Temp1:
LOAD Eno,Product Resident T2;

DROP Table T1;
DROP Table T2;

user8
Contributor III
Contributor III
Author

Below is my script. 

File1 and File2 will change daily but when I reload the app it does not pick up the latest File1 and File2 located in lib://AttachedFiles. Any idea?

File1:
Load 
number
name
From [lib://AttachedFiles/File1.xlsx]
Store File1 into [lib://Folder/File1.qvd] (qvd);

Inner Join 

Load 
number,
product
From [lib://AttachedFiles/File2.xlsx]
Store File1 into [lib://Folder/File1.qvd] (qvd);
Saravanan_Desingh

Hi. Is this (lib://AttachedFiles) a SharePoint? If so, files are checked-in?

user8
Contributor III
Contributor III
Author

lib://AttachedFiles is not a sharepoint. See attached pic.