how can we send even and odd records from a sequential file
to two different targets

Answer Posted / subhash

SeqFile--->Transformer=====>TGTFile1,TGTFile2

1. in SeqFile, add the 'Row Number Column' property and
name it as 'Row_Number'
2. in the Transformer, give the constraint for TGTFile1
link:
'MOD(Row_Number,2)=1'----> all the ODD rows
give the constraint for TGTFile2 link:
'MOD(Row_Number,2)=0'----> all the even rows.


If we use INROWNUM in transformer, then we need to run the
transformer on 'Single' NODE configuration.

Is This Answer Correct ?    18 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how can we validate the flat files using the date in the header and number of records in the flat file? Using both conditions at a time.

2734


how to achieve this output ? Two Input columns(ID & Name) - ID | Name 1 | Jack 1 | Kara In output there should be only 1 column which will be populated as - 1,Jack 1,Kara

363


What is difference between symmetric multiprocessing and massive parallel processing?

654


On which interface you will be working as a developer?

639


What are the different type of jobs in datastage?

608






What is data partitioning?

745


how to sort two columns in single job in datastage.

2533


How do you run datastage job from the command line?

604


what is 'reconsideration error' and how can i respond to this error and how to debug this

2121


What is ibm datastage flow designer?

687


What is the method of removing duplicates, without the remove duplicate stage?

588


What are the processing stages?

644


What is the importance of the exception activity in datastage?

626


sed,awk,head

970


Name the command line functions to import and export the DS jobs?

709