6) my sorce
d1
d2
d1
d2
d1
d3
d2
d1
my target
tartget
1 d1
2 d1
3 d1
4 d1
target2
1 d2
2 d2
3 d3
Target 3
1 d3
Can any body send me answer this is argent requierment
Answers were Sorted based on User's Feedback
1. SRC--->FILTER---->TGT1,TGT2,TGT3
In source query,
SELECT COL1,
RANK() OVER(PARTITION BY COL1 ORDER BY COL1) SNO
FROM TABLE
in filter,
col1='d1'------>TGT1
col1='d2'------>TGT2
col1='d3'------>TGT3
2. SRC---->TFM---->TGT1,TGT2,TGT3
in TFM, do the HASH partitioning on col1 and use the stage
varibles as below:
if col1 =prevCol then SV1=S1+1
else SV1=1
prevCol---->col1
In the link constraints:
TGT1 link, COL1='d1'
map SV1, COL1 to the tgt.
TGT2 link, COL1='d2'
map SV1, COL1 to the tgt.
TGT3 link, COL1='d3'
map SV1, COL1 to the tgt.
| Is This Answer Correct ? | 11 Yes | 0 No |
Answer / ankit gosain
Hi,
The solution to the problem can be achieved by the below
job structure & settings:
Source---->SortStage---->Transformer---->Tgt1,Tgt2,Tgt3
1. In Sort Stage, sort in assending mode w.r.t. source
column (say col1) & Create a change key column (say
ChangeKey).
2. In Transformer stage, create a stage variable (say
count) & it's derivation would be:
if ChangeKey=1 then 1 else count+1
3. Constraint for Tgt1 => col1=d1
Constraint for Tgt2 => col1=d2
select otherwise constraint for Tgt3.
Cheers,
Ankit :)
| Is This Answer Correct ? | 6 Yes | 1 No |
Answer / srinivas
Hii guys use following stages to get output
sequecial file->copy->aggregator and Joinstage then use filter to get required output
by using copy stage take two links one for aggregator and other for Join then you will get
required output
| Is This Answer Correct ? | 1 Yes | 0 No |
WHAT ARE THE COMMON ERRORS IN DATA STAGE?
1.which index is follows the dimensions tables?why? 2.what is the use of trigger in job sequence? 3.what is the mean of optimization? 4.what is the job control?when we use it? what is difference bet batch and sequencer? 6.seq--->seq,seq--->copy--->seq which one is best and efficient?
Out of 4 mill records only 3 mill records are loaded to target and then job aborted. How to load only those 1 mill(not loaded records) for next run. This job is not sequential job, it is stand alone parallel job.What are the possibilities available in datastage8.1?
i have input like this Column 1 ,column 2 3,a 4,b 5.c i want output aaa bbbb ccccc Ple help any one?
there are indexes on a table as index1 with col1, col2 index2 with col2 index3 with col1,col2,col3. if i run a query with col1='100' which index will be used and why
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
i have source like deptno,sal 1,2000 2,3000 3,4000 1,2300 4,5000 5,1100 i want target like target1 deptno,sal 1,2000 3,4000 4,5000 target2 2,3000 1,2300 5,1100 with out using transformerstage
i have a some records eno ename acono amount 1001 suresh sbi101 12000 1001 suresh sbi101 14000 1001 is dublicata how can i remove duplicate?
how do u catch bad rows from OCI stage? And what CLI stands for?
What r the existing server jobs in parallalism?
i want anser this question empno,ename,sal 12,mmm_ww,200 13,nnn_xx,300 14,bbb_qq,400 which stages are take which types of logicks are doing pls help me i don't need "_"ex nnnxx this type i want
what are .ctl(control files) files ? how the dataset stage have better performance by this files?