source
1123445
I WANT OUTPUT AS
DUPLICATES TO TARGET1 LIKE
TARGET1
1144
NON-DUPLICATES TO TARGET2
TARGET2
235

Answers were Sorted based on User's Feedback



source 1123445 I WANT OUTPUT AS DUPLICATES TO TARGET1 LIKE TARGET1 1144 NON-DUPLICATES TO TAR..

Answer / siva

seq.file-->copy-->agg
! !secondary link
!.....>join-------->filter-->t1
primarylink !---->t2
agg:countrows
give condition in filter
count=1-->t1
count<>1-->t2

Is This Answer Correct ?    10 Yes 0 No

source 1123445 I WANT OUTPUT AS DUPLICATES TO TARGET1 LIKE TARGET1 1144 NON-DUPLICATES TO TAR..

Answer / subhash

Source
..|
..|
copy--->agg
..|.....|
..|.....|
join stage
....|
....|
Filter stage -----> target1
..|
..|
target2

the main data is:
1
1
2
3
4
4
5
from aggregator stage, the output is:
1,2
2,1
3,1
4,2
5,1

If you join these two links then the output will be:
1,2
1,2
2,1
3,1
4,2
4,2
5,1

Then specify the count<>1 in the Filter for target1 then you get the duplicate records. means YOU get:
1
1
4
4

in another link for target2, give count=1. means YOU get:
2
3
5

Is This Answer Correct ?    8 Yes 0 No

source 1123445 I WANT OUTPUT AS DUPLICATES TO TARGET1 LIKE TARGET1 1144 NON-DUPLICATES TO TAR..

Answer / s

agg-->filter-->trg2
^ |
| v
seq-->copy-->join-->trg1

agg:countrows
join:innerjoin
filter:count=1
:count>1

Is This Answer Correct ?    0 Yes 0 No

source 1123445 I WANT OUTPUT AS DUPLICATES TO TARGET1 LIKE TARGET1 1144 NON-DUPLICATES TO TAR..

Answer / chaint

source1(112345) ----- lookup stage- reference lookup
on(source2 output)--reject link(1144) --output(235)
source2(112345) -- sort( get count) -> filter(only unique)

we would require two source..
one original and other only (non repeated records)

we will have a lookup stage with source1 as input and
source2 as reference lookup..
in lookup stage we will have a reject link(1144) non matched
records.. and output will be(235).

Kindly correct me if i m wrong

Is This Answer Correct ?    0 Yes 2 No

source 1123445 I WANT OUTPUT AS DUPLICATES TO TARGET1 LIKE TARGET1 1144 NON-DUPLICATES TO TAR..

Answer / nagam

seq.file----->sort------>filter----2datasets

in sort stge create key change column and then filter stage
write the condition on based on keychange column keychange
column =1 uniq data keychange<>0 duplicate data we can get

If wrong please tell me

Is This Answer Correct ?    0 Yes 5 No

source 1123445 I WANT OUTPUT AS DUPLICATES TO TARGET1 LIKE TARGET1 1144 NON-DUPLICATES TO TAR..

Answer / shreeram

Seq(source)------> Transform stage-------> Tgt1
!.........>Tgt2


use substring in transform stage.

Is This Answer Correct ?    0 Yes 11 No

Post New Answer

More Data Stage Interview Questions

Source Like department_no, employee_name ---------------------------- 20, R 10, A 10, D 20, P 10, B 10, C 20, Q 20, S and Output should be like this department_no, employee_list -------------------------------- 10, A 10, A,B 10, A,B,C 10, A,B,C,D 20, A,B,C,D,P 20, A,B,C,D,P,Q 20, A,B,C,D,P,Q,R 20, A,B,C,D,P,Q,R,S

3 Answers  


when U have a remove dublicate option in sort stage, why we have a remove dublicate stage in PX, thought it is recamended to sort data before using a remove dublicate stage. I hae been thinking this from days....

4 Answers   Target,


while we using change capture stage we have to be take two table thats are 1.before table 2. after table . what is before table and after table please give me clear notation Thank You very much in advance

2 Answers   MGL,


Can you explain engine tier in information server?

0 Answers  


what is main difference between change capture and change apply stages

4 Answers   IBM,


what is the difference between 7.1,7.5.2,8.1 versions in datastage?

3 Answers   IBM,


WHAT ARE THE COMMON ERRORS IN DATA STAGE?

6 Answers   IBM, ME,


Emp login_timestamp Logout_timestamp A,2019-02-01 02:24:15,2019-02-01 04:59:42 B,2019-03-29 14:43:30,2019-03-29 20:22:00 ABC,2019-03-29 12:43:00,2019-03-29 23:22:59 In the above calculate the duration of hours spent in office for each emp in datastage.

1 Answers  


What is merge stage?

0 Answers  


when we have to go for a sequential file stage & for a dataset in datastage?

1 Answers  


How can we perform the 2nd time extraction of client database without accepting the data which is already loaded in first time extraction?

0 Answers   Reliance,


What is the difference between datastage and informatica?

0 Answers  


Categories