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
Answers were Sorted based on User's Feedback
Answer / ashok
TRANSFORMER:
------------
STEP1:
Take 3 stage variables
NAME--->s1
if s1<>s3 then LOC else s2:LOC --->s2
s1--->s3
STEP2:
In derivations s2--->LOC Field
Remove duplicate stage:
-----------------------
Retaining last
Is This Answer Correct ? | 7 Yes | 0 No |
Answer / vikram
1)Sort the input (name as key),keychange colum =true
we will get
name loc key..
ram hyd 0
ram ban 1
raj chn 0
raj pun 1
sam del 0
2)transformer
stage variable
svVar=if key..=0 then loc else svVar:loc
3) remove duplicate stage
retain duplicate last
Is This Answer Correct ? | 0 Yes | 0 No |
Answer / venkata ramana
Input Seq File:-
NAME,LOC
Ram,hyd
Ram,ban
Raj,chn
Raj,Pun
Sam,del
seq---Trans---Rem Dups----> Dataset
TRANSFORMER:
------------
STEP1:
Create 3 stage variables like s1,s2,s3
DSLink3.NAME --->s1
If s1<>s3 then DSLink3.LOC else s2:DSLink3.LOC --->s2
s1--->s3
STEP2:
Derivations Column bane
s2------------> LOC
Remove duplicate stage:
-----------------------
Key == NAME
Duplicate To Retain = Last
Output Dataset result:-
NAME LOC
Ram Hyd ban
Raj chn pun
sam del
Is This Answer Correct ? | 0 Yes | 1 No |
Hi Friends, I have a input data like, class_id Marks 101 50 101 60 101 40 102 90 102 35 And i want my output data like class_id Marks Rank 101 50 2 101 60 1 101 40 3 102 90 1 102 35 2 how to do this in datastage?
8 Answers Cognizant, HCL, TIAA CREF,
What is the importance of the exception activity in datastage?
Source contains the metadata source ----- hyderabad,chennai,bangalore by using nested loop sequence select source as hyderabad in target just run target as hyderabad only not others please give me answer thanks in advance(give reply how to wrote logic using nested loop sequence)
How many types of hash files are there?
What are the types of containers and how to create them?
In merge stage can we update the values?
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
What is the difference between odbc and drs stage?
How you Implemented SCD Type 1 & Type 2 in your project?
There are two file are there .1st file contains 5 records and 2nd file contain 10 records in target they want 50 records.how can achieve this
explain about completely flow of sequencers technicaly,without using example??explain about lookup,nullhandling?
for example You have One Table with 4 Columns (Mgr ID, Department ID, Salary, Employee ID). Can you find out the Average Salary and Number of Employee present per Department and Mgr