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...


1.how to generate even numbers in surrogate or tranformar
stage ?

2. how many ways to remove duplicate values?

Answers were Sorted based on User's Feedback



1.how to generate even numbers in surrogate or tranformar stage ? 2. how many ways to remove du..

Answer / subhash

1) By using Stage variables in transformer, we can generate even numbers,
Declare a stage variable - SV1 and initialize to '0'.
In the derivation of that stage variable increment by 2.
i.e. SV1=SV1+2.

By using Surrogate key in transformer, use the below logic in derivation part.
Surrogate_Key -----> If mod(Surrogate_Key,2)= 0 then Surrogate_key Else Surrogate_Key + 10000001

2)Removing Duplicates
a. By using Remove Duplicates Stage.
b. By using SORT Stage,Sort on KEY Column and set 'Allow Duplicates' to 'FALSE'
c. By using Link Partitioning, use 'HASH partition' on KEY Columns and Select Perform Sort and UNIQUE options.
d. By using Transformer Stage Variables,
SV2----->If SV1=KEY_Column then 0 Elso 1
SV1----->KEY_Column
In the Constraint Part give as,
SV2=1

Is This Answer Correct ?    9 Yes 0 No

1.how to generate even numbers in surrogate or tranformar stage ? 2. how many ways to remove du..

Answer / pavan

To generate even numbers using transformer, we can make use
of stage variables. declare a stage variable say SV1 and
initialise it to 0. In the derivation of that stage
variable increment it by 2 which looks like SV1+2. By doing
this we can generate even numbers.

mail me @ akellapavankumar@gmail.com for more info.

Is This Answer Correct ?    6 Yes 0 No

1.how to generate even numbers in surrogate or tranformar stage ? 2. how many ways to remove du..

Answer / kumar

By using distinct we can eliminate duplicates,
by using variable comparison we can eliminate duplicates.

Is This Answer Correct ?    3 Yes 0 No

1.how to generate even numbers in surrogate or tranformar stage ? 2. how many ways to remove du..

Answer / pavan

To remove duplicates we could use Remove Duplicates Stage.
If the requirement states not to use a remove duplicates
stage, u culd use Sort stage, by setting one of its
property Allow Duplicates to false.

Is This Answer Correct ?    4 Yes 1 No

1.how to generate even numbers in surrogate or tranformar stage ? 2. how many ways to remove du..

Answer / kiran

IN surrogate key generator stage set the block size to 2
with initial value as 2, it will increment the surrogates
by 2 and will get you even numbers. I don't think in any
real world scenario you would do this as it violates
surrogate key concept. I wish the interviewer knew this
before he/she asked you.

Is This Answer Correct ?    1 Yes 4 No

Post New Answer

More Data Stage Interview Questions

Hi guys, Please design a job for dis requirement with derivation(solution). my source table like dis. emp_no qualification 1 a 1 c 2 a 3 c 3 b To loaded to target like dis emp_no qualification 1 b 2 b 2 c 3 a my requirement is every employer have three qualifications i.e a,b and c. what qualification missed in source table that will be move to target systems. Hope u got it the requirement. Right Thanks.

0 Answers  


in sequtial file 2 columns avaliable,iwant only one column load the target how do it.

10 Answers   Wipro,


What are the different common services in datastage?

0 Answers  


how do u catch bad rows from OCI stage? And what CLI stands for?

0 Answers  


Differentiate between data file and descriptor file?

0 Answers  


How to RD using transformer?

0 Answers   CTS,


What is the roundrobin collector?

0 Answers  


when we will use connected Lookup & Unconnected Lookup

3 Answers   Wipro,


how to configure databases through datastage

2 Answers  


hi All, i have one scenario like if source--->transformer-->2 target sequential files the 1 st target sequential file is loads the data from source and 2nd target sequntial file contain the 1st target total record count,and file name of 1 st target seq file and timestamp seperated by delimeter for example if source have 10 record the 1st target seq file hav 10 records and 2nd target seq file example 10|xyz.txt|20101110 00:00:00 could you please help me out how can i implement in datastage job.

4 Answers   IBM,


In aggregator stage,to find the sum of the entire group of columns,it displays in binary format. How can i solve this problem.

1 Answers   IBM,


How to create environments and call them? What is the use defined variables?

2 Answers   HCL, ME,


Categories