my source seq file have
col1
1
2
3
4
5
6
7
8
9
i have 4 targets
t1 t2 t3 t4
1 2 3 4
5 6 7 8
9 like this how we can get?
Answers were Sorted based on User's Feedback
Answer / venkatesh
the flow is like this
source---->transformer-------->t1
----------->t2
-------------->t3
------------------>t4
in transformer create a stage variable to calculate mod value
mod(input,4) | mod_value
_________________|____________
in constrain write the condition as
mod_value =1 for t1
mod_value=2 for t2
mod_value=3 for t3
mod_value=0 for t4
try this u will get the required o/p
| Is This Answer Correct ? | 7 Yes | 0 No |
Answer / abd
We can use stage variable in Tran Stage
IF @INROWNUM MOD 4 = 0 then T4
Else If @INROWNUM MOD 4 = 1 then T1
Else If @INROWNUM MOD 4 = 2 then T2
Else If @INROWNUM MOD 4 = 3 then T3
Try this
| Is This Answer Correct ? | 7 Yes | 2 No |
Answer / srikanth
hi
it is possible by using transform stage
select the function in that select the mathematical in that
select the mod function and run the job
you will get the answer
Thanks & regards
srikanth.k
9573056597
| Is This Answer Correct ? | 3 Yes | 3 No |
Answer / jyothi
how this scenario without using MOD operator
if any body know plzzzz tel me...
| Is This Answer Correct ? | 0 Yes | 0 No |
as for as i know,it is simple task only,
order is seq_file->column_generator->tfx->connect 4 targets.
in CG take one more column as SNO(anything)and goto extended column properties- take value=1,value=2,,,upto 4. now write constraint in tfx sno=1 goto t1
sno=2 goto t2...for all targets(4).
if u get other tahn this pls post answer
| Is This Answer Correct ? | 3 Yes | 6 No |
Answer / srikanth
it's a very simple task
select the partition type as round robin
and run the job
you will get the answer
thanks& regards
srikanth
9573056597
| Is This Answer Correct ? | 5 Yes | 11 No |
1)How to do error handling in datastage? 2)Did sequential stage accepts .xl files ,xml? znd how?
What are the main features of datastage?
EXPLAIN SCD
What is the use of hoursfromtime() function in transformer stage in datastage?
I have a scenario like Deptno=10---->First record and last record Deptno=20---->First record and last record Deptno=30---->First record and last record I want those first and last records from each department in a single target. How to do this in DataStage, any one can assist me. Thanks in advance.
How we can convert rows to columns in datastage?
tell me abt Datastage trigger?
on how many columns we can perform aggregation in the Aggregator stage?
How many Nodes configuration file you used in your last project?
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
diff between changecapture & diffrence stage which situvation we can use the diffrence stage ?
create a job to get the previous row salary for the current row.if there is no previous row exists for the current row,then the previous row salary should be displayed as null? empid salary previoussalary 10 1000 null 20 2000 1000 30 3000 2000 40 4000 3000