I am selecting a 4 columns (ID,Code, Name, Time) from my SQL to load in to my target table.
I have to generate a surrogate key only based on 2 specific columns. (Here code and Name). But I need all 4 columns to be part of my output
Is there a way I can specify that ?
Source Table
Code: Select all
ID Code Name Time
1 ABC XYZ Jan
2 ABC XYZ Feb
3 PQR MNO Nov
4 PQR MNO Dec
Code: Select all
Old ID New SK Code Name
1 111 ABC XYZ
2 111 ABC XYZ
3 222 PQR MNO
4 222 PQR MNO