vinod


{ City } hyderabad
< Country > india
* Profession * datastage developer
User No # 73569
Total Questions Posted # 0
Total Answers Posted # 22

Total Answers Posted for My Questions # 0
Total Views for My Questions # 0

Users Marked my Answers as Correct # 109
Users Marked my Answers as Wrong # 38
Answers / { vinod }

Question { IBM, 28835 }

How to exclude first and last lines while reading data into a sequential file(having some 1000 records).I guess probably by using unix filter option but not sure which to use


Answer

In order to exclude the contents while reading from the
sequential file stage we have to use the filter option.

There we have to specify the unix command:

Sed -e '1d' -e '$d'

Is This Answer Correct ?    8 Yes 1 No

Question { 5586 }

What is the use of surrogate key stage?


Answer

Surrogate Key Stage is used to generate the Surrogate Key.

the main purpose of the Surrogate key is to maintain the
complete history in the dimension tables.

Is This Answer Correct ?    1 Yes 1 No


Question { 19604 }

How you Remove the Dataset in Unix?


Answer

sysntax: orchadmin

EX: orchadmin rm big.ds

Deleting the big.ds dataset.

Is This Answer Correct ?    7 Yes 0 No

Question { IBM, 5561 }

How u implement the slowly changing dimensions if my source
table is consisting of cid,cname,add,phno,email but i need to
capture the changes for first three columns how u implement?


Answer

This is done by using the Change_Capture_Stage.

In the CDS stage: specify the change key's--> cid and
change_values as cname,add and phone etc

CDC stage triggers the Change_code as 3 if there is any
changes in the cname or add or phone no for the existing cid.

Ex: cid,cname,add,phone,email
1,'vin','bang','08979','vin@Gmail.com'

REf:
cid,cname,add,phone,email
1,'vin','HYD','08979','vin@Gmail.com'

O/P: cid,cname,add,phone,email,Change_code
1,'vin','HYD','08979','vin@Gmail.com',3

Is This Answer Correct ?    13 Yes 0 No

Question { IBM, 16936 }

i want send my all duplicate record one tar and all uniq
records one target how we will perfome explain
example:
input data
eid
251
251
456
456
951
985
out put/target1
251
251
456
456
out put/target2
951
985
how we will bring


Answer

First use the seq filestage then use the copy stage after
the copy stage one link is going to agregator stage there we
will calculate the count of records after the agregator
stage use filter stage for finding uniq records then those
records are connected to the lookup as a reference link. the
main link for lookup is comming from copy stage. Then
matching records are uniq else duplicate.

Agre--->filter
| |
Seq--->copy---->Lookup---->uniq
|
|
duplicate.

In agregator use count rows.

Is This Answer Correct ?    14 Yes 3 No

Question { IBM, 16936 }

i want send my all duplicate record one tar and all uniq
records one target how we will perfome explain
example:
input data
eid
251
251
456
456
951
985
out put/target1
251
251
456
456
out put/target2
951
985
how we will bring


Answer

Appreciate your Answer but it was wrong..because if you are using Agregator stage it will give only unique records with record count. so how can u print all the duplicate records.


in the above senario:

input to agregator stage: 251,251,456,456,951,985
i used count rows.
so, the o/p is 251,2
456,2
951,1
985,1
if U use the Filter stage then what is the output:
O/P1:
251
456

O/P2:
951
985

Unfortunately this is not the answer we are required...

This is not as simple as U think...i implemented it before posting!!!!!

Is This Answer Correct ?    4 Yes 4 No

Question { IBM, 16936 }

i want send my all duplicate record one tar and all uniq
records one target how we will perfome explain
example:
input data
eid
251
251
456
456
951
985
out put/target1
251
251
456
456
out put/target2
951
985
how we will bring


Answer

Unfortunately, I didn't got the logic behind the YOUR answer.

According your logic: from aggregator stage: the output is this: 251,2
456,2
951,1
985,1
the main data is:
251
251
456
456
951
985

If you join these two links then:
251
251
456
456
951
985
251,2
456,2
951,1
985,1

Then your are specifying that count=1 then you get the unique records.

in another link count<>1 means YOU get 251
456

Unfortunately this is not our desired out put, our out put is: 251
251
456
456

SO, YOUR LOGIC IS NOT ACCEPTABLE. TRY TO THINK FOR DESIRED OUTPUT !!!!

in order to get the desired out put i using the lookup-stage
in lookup i am going to lookup the out put from filter stage which is 951,985 with main data there i will specify the condition as reject:
so YOU will get the desired output!!!!!

If you can prove the above logic is wrong send me the mail!!!!

Is This Answer Correct ?    2 Yes 3 No

Prev    1    [2]