source file having the data like aabbccc, i want target file
result like a1a2b1b2c1c2c3.
Answers were Sorted based on User's Feedback
Answer / srinivas
We can do this with below major steps.
i)First split the data into rows each character as one row this can be done by below function in basic trnsformer
Convert(@TM,@FM,Fmt('aabbccddee', "1T"))
ii)Then next step take four stage variables in next transformer apply below logics
stg1----> Outputcolumn of first transfermer.
stg2----> 1
stge3----> if stg4=stg1 then stg3+1 else stg2
stg4----> stg1
stge5----> stg1:stge3
now we will get the below ansr
o/p column
a1
a2
b1
b2
c1
c2
d1
d2
iii)Then convert the rows into one single column.
Thanks
Srini
| Is This Answer Correct ? | 0 Yes | 1 No |
Answer / ramki
The same logic we can implement for as per the below Q
souce file having the columns like name company krish IBM
pooja TCS nandini WIPRO krish IBM pooja TCS if first row
will be repeat i want the result like this name company
count krish IBM 1 pooja TCS 1 nandini WIPRO 1 krish IBM 2
pooja TCS 2
| Is This Answer Correct ? | 1 Yes | 4 No |
What is the roundrobin collector?
disign the complex job in u r project?(they are aksing only complex job design and then data flow...)
what is A Datastage?
How much data u can get every day? 2)which data ur project contains? 3) what is the source in ur project?what is the biggest table & size in ur schema or in ur project?
I want capture UnMatched records from Primary source and secondary source in JOIN stage?
Name the different sorting methods in datastage.
How did you reconcile source with target?
i have a scenario like two columns(Empno, Ename) in that duplicate records are there, so my question is how to get second duplicate record in datastage.
Can anyone tell me a difficult situation who have handled while creating Datastage jobs?
4) source target c1 c1 c2 c3 c2 c4 c4 c5 c3 c6 c7 c4 c5 c6 c7 please send me answer this question my mail
table actions available in oracle connector?
If there is a file that contains 1000 records, I need the ouput to contain these 1000 records with the header as file name concatenated with the current timestamp and trailer as the count of records