DSXchange: DataStage and IBM Websphere Data Integration Forum
View next topic
View previous topic
Add To Favorites
This topic has been marked "Resolved."
Author Message
arnie_nits
Participant



Joined: 13 Aug 2007
Posts: 96

Points: 748

Post Posted: Thu Jul 29, 2010 8:18 am Reply with quote    Back to top    

DataStage® Release: 7x
Job Type: Server
OS: Unix
Hi I have a requirement where
A1 will become A001
A13 will become A013

Please suggest how to get this.

Regards,
anbu



Group memberships:
Premium Members

Joined: 18 Feb 2006
Posts: 377
Location: india
Points: 1492

Post Posted: Thu Jul 29, 2010 8:33 am Reply with quote    Back to top    

If you always have only one alphabet and followed by any number of digits then try this

Code:
svAlpha=input_field[1,1]
svNum=input_field[2]
target_field=svAlpha : right('000':svNum,3)

_________________
You are the creator of your destiny - Swami Vivekananda
Rate this response:  
Not yet rated
ArndW

Premium Poster
Participant

Group memberships:
Premium Members, Inner Circle, Australia Usergroup

Joined: 16 Nov 2004
Posts: 14005
Location: Germany
Points: 79124

Post Posted: Thu Jul 29, 2010 8:35 am Reply with quote    Back to top    

NewColumn = in.Field[1,1]:FMT(In.Field[2,99],"3'0'R")

_________________
Image
Rate this response:  
Not yet rated
arnie_nits
Participant



Joined: 13 Aug 2007
Posts: 96

Points: 748

Post Posted: Thu Jul 29, 2010 8:45 am Reply with quote    Back to top    

Thanks...it works....

Regards,
Arnie.
Rate this response:  
Not yet rated
Display posts from previous:       

Add To Favorites
View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



Powered by phpBB © 2001, 2002 phpBB Group
Theme & Graphics by Daz :: Portal by Smartor
All times are GMT - 6 Hours