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 .
Answers were Sorted based on User's Feedback
Answer / dipal
step-1
Filter the record based on condition
Flag1=N AND Flag2=N ....link1
also defined a reject link
step-2
read link1 as left link and reject link as right link and
do inner join with Look up stage based on id
also define a reject link.
now the reject link will have required output.
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / vz
Put a constraint in Transformer stage as shown bellow.
flag1=y or flag2=y
means
feald1=y or feald2=y
I think it's help you.
| Is This Answer Correct ? | 3 Yes | 1 No |
A flat file contains 200 records. I want to load first 50 records at first time running the job, second 50 records at second time running and so on, how u can develop this job?
What is exact difference between Parallel Jobs and server Jobs..
how many write modes are there in ds
How do you remove duplicate values in datastage?
DB2 connector> transformer > sequential file Data will be exported into a csv format in a sequential file. This file will be send in a email using a sequence job. Problem here is, how to avoid sending a blank csv file? When I ran the job there are chances that it might return zero records but in the sequence job csv file is going blank. how can I avoid this? thanks
how to sort two columns in single job in datastage.
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.
what is main difference between change capture and change apply stages
What is the difference between odbc and drs stage?
Hi Can any one help regarding below INPUT NAME LOC Ram hyd Ram ban Raj chn Raj Pun Sam del OUPUT NAME LOC Ram Hyd ban Raj chn pun sam del
CHANGE CAPTURE
how to closeing records after 10,000 records come?