Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
Situation: I want to Join OrderId table with Main_Table by [Number] field.
I want to record Channel/Source/Campaing values from OrderId to the Main_Table (currently there are no values there), where Map = Table2
The script:
Left Join (Main_table)
Load
'Table2' as map,
number,
channel,
source,
campaign
RESIDENT OrderIdSourceTMP;
Drop Table OrderIdSourceTMP;
The problem is that the tables are not joined because Channel/Source/Campaign in MainTable are considered to exist, although they equal to zero.
Is there a magic sauce?
Thank you!
It looks like what you need is called an Outer Join, those exist in SQL too.
https://help.qlik.com/en-US/sense/June2018/Subsystems/Hub/Content/Scripting/ScriptPrefixes/Outer.htm
I think if you just use 'Join' in instead of 'left join', it would create new row in the final table, not sure if you want 'social, facebook,123' to reflect in the same row where 'xxx', 'yyy' exists or another row would do.