Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
SDeLa131
Contributor II
Contributor II

Concat two or three fields into one and then link the two files that have the order number.

I have two files, each file contacts company number, ordernumber, and backorder number. The fields are not named the same. Was looking to concat the three fields into one and call it OrderID.  Then associate the field OrderID, from the two files to pair. 

Maybe this is not the right way of performing or not but appears within the data load concat is not working. I have a trial version of qliksense to the cloud.  

 

I tried to rename the fields in the file to be the same and then I get $syn 1 table when viewing the data model viewer which I don't believe is a good practice. 

 

Labels (1)
3 Replies
RafaelBarrios
Partner - Specialist
Partner - Specialist

Hi @SDeLa131 

If you want to keep it simple and keep the three tables, yo need to make a key field and then rename the fields in two of the tables or not load on them.

so, would be something like:

load
     [ORDER NO]&[BACKORDER NO] AS KEYFIELD,
    *
from table1

do the same in the other two tables but don’t load ORDER NO] and [BACKORDER NO] individually or use an alias for those

 [ORDER NO] as  [TABLE2 ORDER NO]
 [BACKORDER NO] as  [TABLE2 BACKORDER NO]

 

hope this helps.

Best,

Help users find answers! Don't forget to mark a solution that worked for you & to smash the like button! 🙂

SDeLa131
Contributor II
Contributor II
Author

I was hoping to link the main order number example 12345 to the backorder to make it a unique order. example 12345001 vs 12345000. This would be two unique orders in Qliksense. We have it designed this way in qlikview. 

 

vinieme12
Champion III
Champion III

Consolidate common keyfields into one link table

 

 

LinkTable:

Load ORDERNO&'-'&BACKORDERNO as key

From VCODETLsource;

JOin(LinkTable)

Load ORDERNO&'-'&BACKORDERNO as key ,CustomerNo

From VCOHEADsource;

 

 

VCODETL:

Load * , ORDERNO&'-'&BACKORDERNO as key
From VCODETLsource; //exclude or rename fields ORDERNO and BACKORDERNO to avoid syn key

 

VCOHEAD:

Load * , ORDERNO&'-'&BACKORDERNO as key

From VCOHEADsource; //exclude or rename fields ORDERNO and BACKORDERNO to avoid syn key

 

VARCUST:

Load *

From VARCUSTsource;

 

Finally

Tables VCODETL and VCOHEAD should associate with LinkTable using "key" field

Table VARCUST should associate to LinkTable with "customerNo" field

 

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