Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have 3 tables and my requirement is,
1.Cust_no and Cust_name from A and B table should map
2.Cust_no from B and C table should map
Please assist me
A:
LOAD Cust_no ,
Cust_name,
Dept,
City,
Phone
FROM
C:\Users\257679\Desktop\Applymap.xlsx
(ooxml, embedded labels, table is Sheet1);
B:
LOAD Cust_no,
Address,
region
FROM
C:\Users\257679\Desktop\Applymap.xlsx
(ooxml, embedded labels, table is Sheet2);
C:
LOAD Cust_no,
Cust_name
resident A;
Hi,
To avoid Syntethical keys you should make sure that only one field from each of you tables is linked to another table.
But why do you want to split your source into three tables? Why not just load it as one table?
br Paul
Hi,
As per your post do the following thing .I dont know why you want to do like this.
To Remove Synthetic key always rename the field which you doesnot want as linking with other table.
A:
LOAD Cust_no ,
Cust_name,
Dept,
City,
Phone
FROM
C:\Users\257679\Desktop\Applymap.xlsx
(ooxml, embedded labels, table is Sheet1);
B:
LOAD Cust_no,
Cust_no as CustNo1,
Address,
region
FROM
C:\Users\257679\Desktop\Applymap.xlsx
(ooxml, embedded labels, table is Sheet2);
C:
LOAD Cust_no as CustNo1,
Cust_name as Cust_name1
resident A;
Regards,
Nirav Bhimani
Hi,
Can you please Attach the Sample Application.
Hi,
Please tell me Why you are creating a new table C
1.Cust_no and Cust_name from A table should map to Cust_no and Cust_name in B table
2.Cust_no from B should map to Cust_no in C table
Using common field as key in your table can avoid creating synthetic keys
A:
LOAD * ,Cust_no&Cust_name as key Inline [
Cust_no,Cust_name, Dept, City,Phone
123, A ,Sales ,Bang ,0908088
];
B:
LOAD Address,region,Cust_no&null() as key Inline [
Cust_no,Address,region
216,bang,south
];
C:
LOAD Cust_no&Cust_name as key;
LOAD Cust_no,
Cust_name
resident A;
Hi,
My friend CustName is not there in table B, I still confused why you want resident table C:??????
Kindly expalin in brief so that it would be more clear or else share a demo file for further help.
Regards,
Nirav Bhimani