i/p
1,a,1000
2,b,2000
3,c,3000
i want to get o/p as
o/p
1,a,3000
2,b,4000
3,c,5000
how it can be done on using datastage?

Answers were Sorted based on User's Feedback



i/p 1,a,1000 2,b,2000 3,c,3000 i want to get o/p as o/p 1,a,3000 2,b,..

Answer / ra

Simple.

ano,aname,amt
1,a,1000
2,b,2000
3,c,3000
column derivation write like this (amt+2000) then we will get o/p

Is This Answer Correct ?    16 Yes 1 No

i/p 1,a,1000 2,b,2000 3,c,3000 i want to get o/p as o/p 1,a,3000 2,b,..

Answer / hussy

Hi,

My suggestion is instead of calculating for each column.

Create a stage variable (amt+2000)----> STG1

Call this STG1 in your derivation output amount column.

Is This Answer Correct ?    7 Yes 0 No

i/p 1,a,1000 2,b,2000 3,c,3000 i want to get o/p as o/p 1,a,3000 2,b,..

Answer / karthi

how can u do this in tfm explain

Is This Answer Correct ?    1 Yes 4 No

i/p 1,a,1000 2,b,2000 3,c,3000 i want to get o/p as o/p 1,a,3000 2,b,..

Answer / saran

in TFM stage we are mapping i/p records to o/p
then i/p metadata appear in o/p link then go to required column o/p link write there derivation whatever we want
in TFM stage
ex--- ano,aname,amt
1,a,3000
2,b,4000
3,c,5000
column derivation write like this (amt+1000)

Is This Answer Correct ?    1 Yes 12 No

i/p 1,a,1000 2,b,2000 3,c,3000 i want to get o/p as o/p 1,a,3000 2,b,..

Answer / saran

using TFM stage we can get o/p like this
in TFM stage write derivation on column level
i.e link.column+1000

Is This Answer Correct ?    0 Yes 13 No

Post New Answer

More Data Stage Interview Questions

what is the new version in Datastage ? what is the diff b/t New vesion & 7.5 version?

12 Answers   Wipro,


I have a input as: Col 1 1 2 2 3 I want 3 output as: Output1: 1 1 Output2: 2 2 Output3: 3 i.e. same duplicates should be in one target, other duplicate values should be in another target and so on.. Pls help

9 Answers   IBM,


input Name Salay Sam 10 Sam 30 Sam 20 Ram 40 Ram 50 Output should be Name Salary Count Sam 10 3 Ram 40 2 get min salary and count of name . OutPut 2 Name Seq Sam 1 Sam 2 Sam 3 Ram 1 Ram 2

1 Answers   HCL,


Which type of joins Merge stage can support?

7 Answers   IBM,


i want job aborted after some records are loaded into output by using only sequential stage and dataset

1 Answers   IBM,






What is the sortmerge collector?

0 Answers  


What is the Main difference between Lookup Failure and Lookup Not Met? Plz explain with Example.

2 Answers  


What are the stages in datastage?

0 Answers  


wt is the diff b/w odbc and oracle stage

2 Answers   Accenture, HCL,


Define Routines and their types?

0 Answers  


A table containg 100 records B table containg 20 records we have to join two tables in left outer it containg target 100 records but target containg 101 record at that time what is the issue arise

3 Answers   Polaris,


WHAT ARE THE STAGES U WILL USE IN IMPLEMENTING SCD2/DATE FIELD

8 Answers   L&T,


Categories