Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, why are there duplicate rows? I concatenated tables from different sources and 'itemnum' is primary key. The itemnum appears in all the tables and has data for all columns but still duplicates, for example, it has data for all the columns from one table but is null for the other columns in other tables. So there is duplicate like below:
itemnum | site | name | balance | class | code | Group |
---|---|---|---|---|---|---|
1009 | A | D | - | B | - | - |
1009 | - | - | 45 | - | FG | H |
How can I combine everything to one row (distinct itemnum)?
itemnum | site | name | balance | class | code | Group |
---|---|---|---|---|---|---|
1009 | A | D | 45 | B | FG | H |
Thanks.
Try join instead of concatenation
can you pls share the datamodel picture?
Hi
You will need to join rather than concatenate to get them on the same row. Post more details of your data and script for more detailed help on how to do so.
HTH
Jonathan
Oh yes, sorry I meant join. I used 'outer join'.
I have used 'outer join'.
Is there any other way for you to help me? Because I can't post the data...so sorry.
Sorry, what is datamodel picture?
concatenate will always add separate row, but join on primary key can help you to remove duplicate
There is something wrong with your join. To get help, you will need to post your load script and some more details of your data. Best solution is to upload your model here.
Jonathan