Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Everyone,
I'm trying to join two tables with one key field.
However, my problem is it keeps on separating the data into two and adding a null.
I'm expecting that it should be 1 liner approached.
On the image, I want to merge the two lines using the matching Keyfield column.
I expect it to be like this:
I hope you can help me how I handle it on the Load scripting.
Thank you!
A simple join would do this rite , not sure how your joining the tables .
Could you share the code details here so that we could identify the issue
Hi,
This is how I join it.
I know how to use join but I don't know why it shows that result.
Could you please share the column names in each table
I feel you have similar column name in both the tables e.g. order Year and its blank in one table and have value in another table that is why its causing the 2 rows
One solution is in each table try to load only the columns without values and then join with the other table.
If it still doesn't work share the sample data will help you out
Yes, I have a similar column name for Table 1 and Table 2.
And the logic is to join them into one and merge it using the KeyField I've mentioned.
I hope that makes sense.
Thanks!
Without sample data its hard to provide the exact solution . Try like below
Table_A:
Load
Keyfield,
OrderYear,
OrderMonth,
Source,
ORNumber
from
TableA;
//note : make sure this columns has data in it
join(Table_A)
Load
Keyfield,
SalesYear,
SalesMonth,
Target
from
TableB;