Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

source file having the data like aabbccc, i want target file
result like a1a2b1b2c1c2c3.

Answer Posted / 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



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

explain about citrix scheduling tool in datastage

2379


Where do the datastage jobs get stored?

1149


What is use Array size in datastage

1719


How complex jobs are implemented in datstage to improve performance?

962


How to Remove Duplicate using SQL?

1290


i have a job with 3 possibiliies finish with ststus ok abbort warning how do you handle these 3 in job sequence? explain the situation where you have appiled scd in your project? chandu

2676


how to export or import the jobs in .ISX file

1132


What is the difference between passive stage and active stage?

1412


what is repositery?

1767


Explain usage analysis in datastage?

1095


Triggers,VIEW,Procedures

1175


What is the use of datastage director?

972


Is it possible to query a hash file?

1951


how to connect source to db?generally what r stages u used? how to find the data is having delimiter format?

2324


Why do we use link partitioner and link collector in datastage?

1076