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

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
siem
Partner - Contributor II
Partner - Contributor II

Concatenate 2 tables

Hello, I got this script : 

STOCK:
Qualify *;
Unqualify [ID ARTICLE];
LOAD
Date_Stock,
"No Magasin",
"Code Article" as [ID ARTICLE],
"Stock Total",
"Stock Dispo",
"Stock Transit"
FROM [lib://Google_Drive - Stocks_2019.xlsx];


LOAD
Date_Stock,
"No Magasin",
"Code Article" as [ID ARTICLE],
"Stock Total",
"Stock Dispo",
"Stock Transit"

FROM [lib://Google_Drive - Stocks_2020.xlsx];

unqualify *;

 

 

When I execute script, i got 2 distinct tables.

I would like to have just 1 table with 6 field.

 

Thanks in advance

Labels (3)
1 Reply
MayilVahanan

Hi

Try like below

LOAD
Date_Stock as Stock.Date_Stock,
"No Magasin" as Stock.NoMagasin,
"Code Article" as [ID ARTICLE],
"Stock Total" as Stock.Total,
"Stock Dispo" as Stock.Dispo,
"Stock Transit" as Stock.Transit
FROM [lib://Google_Drive - Stocks_*.xlsx];

Or
If you have more fields and difficult to change manually, try like below

STOCK_Temp:
LOAD
Date_Stock,
"No Magasin",
"Code Article" as [ID ARTICLE],
"Stock Total",
"Stock Dispo",
"Stock Transit"
FROM [lib://Google_Drive - Stocks_*.xlsx];

Qualify *;
Unqualify [ID ARTICLE];
Stock:
Load * resident STOCK_Temp;
unqualify *;

Drop table STOCK_Temp;

 

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.