Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone,
I have a problem with the join.
I would like to execute a join between 3 tables and keep the result table for reporting.
[MAP PRODUCT HFM 2017]:
LOAD
[HFM CODE] AS [HFM CODE-HFMCode],
[DESCRIPTION],
[Plant abbr],
....
FROM lib...
(ooxml, embedded labels, header is 1 lines, table is [MAP PRODUCT HFM 2017]);
[MAP MARKET 2017]:
LOAD
[Market Code] AS [Market-Market Code],
[REGION] AS [Plant_Region-REGION],
...
FROM lib...
(ooxml, embedded labels, header is 1 lines, table is [MAP MARKET 2017]);
[MAP BRAND 2017]:
LOAD
[Scenario] AS [MAP BRAND 2017.Scenario],
[Format],
[Years],
...
FROM lib...
(ooxml, embedded labels, header is 1 lines, table is [MAP BRAND 2017]);
[HFM DB]:
LOAD
[Year],
[Scenario] AS [HFM DB.Scenario],
[Month] AS [HFM DB.Month],
[Brand],
...
FROM lib...
(ooxml, embedded labels, header is 1 lines, table is [HFM DB]);
I'd like to execute an outher join:
HFM DB with MAP MARKET 2017 by MARKET CODE
HFM DB with MAP PRODUCT HFM 2017 by HFM CODE
HFM DB with MAP BRAND 2017 by BRAND
At last I'd like to keep the result table from this outher join.
Thanks in advantage,
Livio
OK, but I'd like to save the result of join in a different table so I can export it
OK, but I'd like to save the result of join in a different table so I can export it
because first he need to export the result from one table which contains the result of all the joins mentioned above, and second, when i join tables, i really need to join, otherwise i use keep or i let Qlik make the natural keep by the column names
But this:
[HFM DB]:
LOAD
FROM TABLE;
OUTER JOIN([HFM DB])
[MAP PRODUCT HFM 2017]:
LOAD
FROM TABLE;
DROP TABLE [MAP PRODUCT HFM 2017];
will result in an ERROR. when u do make the join; Qlik will only keep one table ([HFM DB]);
so:
DROP TABLE [MAP PRODUCT HFM 2017];
=> Error ; table not existing : [MAP PRODUCT HFM 2017]
I mean sthing like this:
table1:
load * Inline [
fielda
1
2
3
];
Outer Join(table1)
table2:
load * Inline [
fielda,fieldb
1,b
2,c
3,a
4,d
];
Drop Table table2;
Exit Script;
result:
In which way i can save the outher join result in a table from exporting??
What do you mean by exporting a table?
I'd like to create a table [HELLO] that contains some of the columns resulted from the outher join, so i can export it and use it for another analysis.
yes thats what i want to do (keep only a table), i just forgetting to not explicitly name the tables before join
With the script Youssef gave u (alter it to ur needs); you'll have on resulting table which is :[HFM DB]
youu can then store this table in a qvd : https://help.qlik.com/fr-FR/sense/June2017/Subsystems/Hub/Content/Scripting/ScriptRegularStatements/...
and use it in another application if u want to.