if a column contains data like
ram,rakesh,madhan,suraj,pradeep,bhaskar then I want to
place names separated by commas in another columns how can
we do?
Answers were Sorted based on User's Feedback
seq file ------> Transformer -------> target
1.extract the source data into seq file.
2.In transformer source column to target , and apply the field function
Field(column name, ',' , 1)
next same drag the source column to target , and apply the field function
Field(column name,',',2)
.
.
.
Field(column name,',',5)
| Is This Answer Correct ? | 8 Yes | 0 No |
Well the Question is not clear at the moment.
if ur question is
1)single col with single row like
name
ram,rakesh,madhan,suraj,pradeep,bhaskar
then
ur requirement of asking is again this?
like
ram,rakesh,madhan,suraj,pradeep,bhaskar
or
2)single col with multiple rows like
ram
rakesh
madhan
suraj
pradeep
bhaskar
and u want o/p like ram,rakesh,madhan,suraj,pradeep,bhaskar.
Then praney anwer doesn't suite to get output.
neither u can use pivot stage using vertical pivoting bec
what will u pivot and group by.... not possible.
Finally one way is:
Use SeqStg-->ColGen-->Tx-->RemDup-->Dataset.
At colgen give a new column and assign 1 to all rows and
send the result to tx.
At tx take three variables and expressions to concatenate
the input with the help of colgen new column.
Hint: If sv1 <> sv3 Then DSLink45.cname Else sv2 : ',' :
At RemDup specify Last value
And finally u will the output.
Still if u dont get what i explained just mail me
shharrath@yahoo.com
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / santhu
Then We have to concatenate by using concatenation operation with comma(,)in transformer
| Is This Answer Correct ? | 1 Yes | 2 No |
Answer / abhishek
No Need of fileds and all extraact al the columns in
transfarmerstage create a new column in transe as exprestion
col1,col2,col3 and load it
| Is This Answer Correct ? | 0 Yes | 3 No |
With out using Funnel Stage, how to populate the data from different sources to single target
HOW CAN WE SEE THE DATA IN DATASET?
what is parameterset?
how to define satge variables in transformer stage
What are the third party tools you used in your project?
cust id,cust quty like 1,101;1,102;1,103 i want output like cust id,cust quty 1 101,102,103 in oracle please write a query in oracle
how to capture rejected data by using join stage not for lookup stage. please let me know
What are the enhancements made in datastage 7.5 compare with 7.0?
how do u capture duplicates through sort & transformer
Differentiate between datastage and datastage tx?
i/p o/p1 o/p2 1 1 4 1 1 5 1 1 6 2 2 2 2 2 2 3 3 4 5 6 how to populates i/p rows into o/p1&o/p2 using datastage stages?and also the same scenario using sql?
In Datastage, how you can fix the truncated data error?