.

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
babbu
Participant
Posts: 18
Joined: Mon May 19, 2008 10:57 pm

.

Post by babbu »

.m
Last edited by babbu on Sun May 25, 2008 7:25 am, edited 1 time in total.
babbu
Participant
Posts: 18
Joined: Mon May 19, 2008 10:57 pm

Post by babbu »

please suggest
thanks
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Babbu, you didn't ask a question. Is this function not working, and if so, what output do you get? What is the data type of the resulting column? It it is still integer then remember, numeric columns have no leading zeroes, so you string function would create a valid string with leading zeroes, which would then get converted implicitly back to an integer.
babbu
Participant
Posts: 18
Joined: Mon May 19, 2008 10:57 pm

Post by babbu »

when i am using the above function iam getting the same output without any change


wat condition can i use to get the above output if function cant be used.
thanks
Last edited by babbu on Sun May 25, 2008 7:27 am, edited 1 time in total.
babbu
Participant
Posts: 18
Joined: Mon May 19, 2008 10:57 pm

Post by babbu »

the datatype is same
Last edited by babbu on Sun May 25, 2008 7:30 am, edited 1 time in total.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

you cannot append leading zeroes to an integer. Change your output datatype to VarChar() to get your Str() function to work.
babbu
Participant
Posts: 18
Joined: Mon May 19, 2008 10:57 pm

Post by babbu »

thanks
Last edited by babbu on Sun May 25, 2008 7:27 am, edited 1 time in total.
babbu
Participant
Posts: 18
Joined: Mon May 19, 2008 10:57 pm

Post by babbu »

.
thanks
Last edited by babbu on Sun May 25, 2008 7:31 am, edited 1 time in total.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Hello Babbu, you don't seem to understand the concept - numbers (integer,real,decimals) are stored as binary values and there is no concept of leading zeroes or any other formatting. That comes about when the value is displayed or converted to a string.
In your example you created a nicely formatted string with leading zeroes which DataStage then converted back into a binary format. You need to change the formatting when outputting the number and cannot do it where you are currently attempting to do so.
babbu
Participant
Posts: 18
Joined: Mon May 19, 2008 10:57 pm

Post by babbu »

thnks now i got the concept
:D
Post Reply