Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


i have source like
deptno,sal
1,2000
2,3000
3,4000
1,2300
4,5000
5,1100

i want target like

target1
deptno,sal
1,2000
3,4000
4,5000

target2
2,3000
1,2300
5,1100


with out using transformerstage

Answers were Sorted based on User's Feedback



i have source like deptno,sal 1,2000 2,3000 3,4000 1,2300 4,5000 5,1100 i want target like..

Answer / sarath

first generate the surrogate key (eg rownum). then using the filter stage give the condition where= (rownum%2=0) to one dataset and rejected to another dataset.
I think this will work.

correct me if im wrong.

Is This Answer Correct ?    10 Yes 0 No

i have source like deptno,sal 1,2000 2,3000 3,4000 1,2300 4,5000 5,1100 i want target like..

Answer / rafi

by using round robin partition with two nodes we can get the solution.

Is This Answer Correct ?    8 Yes 4 No

i have source like deptno,sal 1,2000 2,3000 3,4000 1,2300 4,5000 5,1100 i want target like..

Answer / naveen

seq1---------seq2


seq1 read the file.

seq2 ----give outfile1 and click on file give outfile2 then partition tab then select roun rabin partition key first column.

get the desired output.

Is This Answer Correct ?    1 Yes 1 No

i have source like deptno,sal 1,2000 2,3000 3,4000 1,2300 4,5000 5,1100 i want target like..

Answer / mrvprasad

1)First go to Seq File-->Columns-->Add RowNum column and
2)then go to Properties-->select Options-->select Row Number Column=RowNum (Drop down list select RowNum column)
we will get the sequence Numbers.

first do the link sort for Sal in transformer stage.

and in Transformer stage go to
Constraint: Mod(dslink1.RowNum,2)=0 ---o/p1

and then select otherwise check box or write Mod(dslink1.RowNum,2)=1 --->0/p2

Is This Answer Correct ?    0 Yes 1 No

i have source like deptno,sal 1,2000 2,3000 3,4000 1,2300 4,5000 5,1100 i want target like..

Answer / saran

using filter stage we can get output
in filter stage in where clause write condition like this
where sal in(2000,4000,5000) this to one dataset link
and specify reject link to another dataset

Is This Answer Correct ?    0 Yes 2 No

i have source like deptno,sal 1,2000 2,3000 3,4000 1,2300 4,5000 5,1100 i want target like..

Answer / thippareddy.p

From source copy the data into sets using copy or peak
stage then for each copy stage use remove duplicate stage
with duplicate to retain first and last you will get
desired output.....
Hope thios will help u.......

Is This Answer Correct ?    1 Yes 16 No

Post New Answer

More Data Stage Interview Questions

Can you explain tagbatch restructure operator?

0 Answers  


ename like ibm,tcs,hcl need display those records only how?

2 Answers  


Give an idea of system variables.

0 Answers  


how to find out number of records imported into source file?

1 Answers  


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

1 Answers   IBM,


how to do pergformence tuning in datastage?

4 Answers   MCA, Symphony, TCS,


Drop duplicate records ... SOURCE LIKE .......... ID flag1 flag2 100 N Y 100 N N 100 Y N 101 Y Y 101 N Y 102 Y N 103 N N 104 Y Y 105 N N 106 N Y 102 N Y 105 Y Y in above file if any id having both the flags as "N" then that corresponding id records should be dropped, in above case o/p should be as ID flag1 flag2 101 Y Y 101 N Y 102 Y N 102 N Y 104 Y Y 106 N Y Steps to do : 1) Identified the id’s that got duplicated (both the flag values having vales “N”) 2) Look up with these id’s to existing id’s to drop .

2 Answers  


How do you import and export data into datastage?

0 Answers  


What is container and then types?

1 Answers  


What is the difference b/w Hash file and Lookup Fileset stages?

1 Answers  


deptno wise to find max and min,and sum of rows and in target to company wise maximum

1 Answers   IBM, TCS,


How one source columns or rows to be loaded in to two different tables?

0 Answers  


Categories