We have moved to www.dataGenX.net, Keep Learning with us.

Wednesday, March 19, 2014

DataStage Scenario - Problem18



Goal : Get the y'day date as a column and change the column format

 
 
Input :

Country|Currency|ValidFrom|ExRate
CNH|USD|1-Jan-12|0.11
CNH|USD|5-Jan-12|0.8
CNH|USD|10-Jan-12|0.15
CNH|USD|15-Jan-12|0.14
CNH|USD|20-Jan-12|0.16



Output : 
 
Country,Currency,ValidFrom,ValidTo,ExRate
CNH,USD,20-jan-12,19-jan-12, 00.160
CNH,USD,15-jan-12,14-jan-12, 00.140
CNH,USD,10-jan-12,09-jan-12, 00.150
CNH,USD,05-jan-12,04-jan-12, 00.800
CNH,USD,01-jan-12,31-dec-11, 00.110


No comments :

Post a Comment