Page 2 of 2

Posted: Sun Mar 11, 2007 7:58 pm
by kumar_s
As noted by Craig, whats your end result when you change this?
Dont just rely on Veiw data, look out in the target database.
I tried by changing the data type for that column at source with Decimal[42,2] and couldn't able to view the data itself.

Posted: Mon Mar 12, 2007 12:57 am
by san_deep
Thanks Kumar for your time and info.
Kumar_S wrote:whats your end result when you change this? Dont just rely on Veiw data, look out in the target database.
How is it possible to reach upto target if i am not being able to view the data at the source level?

Will the job run when there is a import error at the source level itself?

Please correct if i am going wrong somewhere.

Posted: Mon Mar 12, 2007 12:59 am
by kumar_s
"Fatal Error: APT_Decimal::assignFromString: the source string (322665901919233341505776723281119128249 ) is out of range for the decimal with precision 38."
Do you get the same error for this case also?

Posted: Mon Mar 12, 2007 2:50 am
by san_deep
The above error i got while i was converting that number to char by using TO_CHAR function [This is only way i was able view the data at source level] and then using DecimalFromString function in transformer and changing my target data type to Decimal[42,2].

But as per the info from prior post it was suggested that do it without converting it to char.

So i am confused how to do it?

Posted: Mon Mar 12, 2007 4:38 am
by kumar_s
As suggested, Use TO_CHAR in the source and convert it into Char data type, pass it till the target, and User TO_NUMBER to convert it back to Decimal.
Have you just tried with Decimal[42,2] and run the job (not just view the data)? Did you got any error? Would you be able to find the data in output?

Posted: Mon Mar 12, 2007 7:04 am
by chulett
kumar_s wrote:As suggested, Use TO_CHAR in the source and convert it into Char data type, pass it till the target, and User TO_NUMBER to convert it back to Decimal.
Have you just tried with Decimal[42,2] and run the job (not just view the data)? Did you got any error? Would you be able to find the data in output?
AFAIK - There should be absolutely no need for the TO_CHAR / TO_NUMBER dance. And allegedly no need for any scale on the number. How about we stick with the suggestion of using something like Decimal[40] from end to end and see what happens? Or Decimal[42] it that floats your boat.

Posted: Mon Mar 12, 2007 8:36 pm
by kumar_s
I was suggesting to give a run and check the target with Decimal(42). But OP is very sticky with TO_CHAR that you suggested initially as the worst case. :wink: