Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Greetings Gurus,
I have a cross table whose fields I want to use in creating a link field.
The link field will be a combination of [(Table 1......).FinYear] & [PriceBrand] & [Size] as LinkKey
Below is the load script.
CROSSTABLE ([Size],[Price],2)
LOAD
[(Table 1......).FinYear],
[PriceBrand],
[1L],
[2L],
[500ml],
[250ml]
RESIDENT [_temp_af07bda5-5af6-41a1-7169-fd954c8e];
This should work:
Transformed:
Load
[(Table 1......).FinYear],
[PriceBrand],
[Size],
[Price],
[(Table 1......).FinYear] & '|' & [PriceBrand] & '|' & [Size] as LinkKey
Resident [(Table 1...)]
- Marcus
It couldn't be done directly within the crosstable but you could do it in a following resident load.
- Marcus
Thanks Marcus,
Tried that but its not appearing in the Data Model Viewer. I am missing something
Transformed:
Load
[(Table 1......).FinYear],
[PriceBrand],
[Size],
[Price]
Resident [(Table 1...)]
This should work:
Transformed:
Load
[(Table 1......).FinYear],
[PriceBrand],
[Size],
[Price],
[(Table 1......).FinYear] & '|' & [PriceBrand] & '|' & [Size] as LinkKey
Resident [(Table 1...)]
- Marcus
Like magic!!
Thank you so much.