Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Can you help me? I would like to add column and its values from Table.2 to Table.1 via same ID fields, like in this example:
Table.1
xxx.ID | Table.1 measure.type.1 | Table.1 measure.type.2 | Table.1 measure.type.3 |
---|---|---|---|
A116 | 50 | 4 | 450 |
A117 | 49 | 5 | 500 |
A118 | 37 | 9 | 460 |
Table.2
xxx.ID | Table.2 col.1 | Table.2 col.2 |
---|---|---|
A116 | N | Q |
A117 | A | W |
A118 | B | E |
Desired Table:
xxx.ID | Table.1 measure.1 | Table.1 measure.2 | Table.1 measure.3 | Table.2 col.1 | Table.2 col.2 |
---|---|---|---|---|---|
1 | 50 | 4 | 450 | N | Q |
2 | 49 | 5 | 500 | A | W |
3 | 37 | 9 | 460 | B | E |
We are talikng about two different table , but with same ID's.
I also would like to do a crosstable on Table.1 which is working for me, but I need the second table col1. and other values as well.
If I do crosstable on table.1 the xxx.ID will appear as many as attribute masure exist. (example: ID: A116 has three different masure types in this case: 50; 4; 450 )
I would like to filter the mesured types, and its values via filtering, - which is also work for me - , if i do a crosstable with auxiliary table of attributes.
The problem is I will not know the second table col.1 and col.2 result/status.
Thank you , if you can help me!
Best Regards,
Zoltán
Hi Zoltán!
If you are sure, that every ID in the tables are unique, you can use left join in load script (We are talking about load script right?)
table1:
Load
Id,
columns....
from/resident [table1];
left join(table1)
Load
Id,
columns....
from/resident [table2];
That performs a simple leftjoin on the table 1.
Hope this helps.
G.
Hi Zoltán!
If you are sure, that every ID in the tables are unique, you can use left join in load script (We are talking about load script right?)
table1:
Load
Id,
columns....
from/resident [table1];
left join(table1)
Load
Id,
columns....
from/resident [table2];
That performs a simple leftjoin on the table 1.
Hope this helps.
G.