Page 1 of 1

Parsing error

Posted: Fri Nov 10, 2006 7:04 am
by ajith
Transformer_2,0: Parsing parameters "" for schema type "decimal": Expected precision; got: <eof>
Parsing parameters "" for schema type "decimal": Expected precision; got: <eof>
Parsing parameters "" for schema type "decimal": Expected precision; got: <eof>
Parsing parameters "" for schema type "decimal": Expected precision; got: <eof>
Parsing parameters "" for schema type "decimal": Expected precision; got: <eof>
Parsing parameters "" for schema type "decimal": Expected precision; got: <eof>
Parsing parameters "" for schema type "decimal": Expected precision; got: <eof>
Parsing parameters "" for schema type "decimal": Expected precision; got: <eof>

When I am running my job I get the error, I use some stringtodecimal functions in the job. I am not understanding why I get the error.

I use
If ( TrimLeadingTrailing(DSLink4.DEPN_NBR) = '' ) then 999 else If (Isvalid( "decimal", StringToDecimal(TrimLeadingTrailing(DSLink4.NBR)))=0) then 999 else StringToDecimal(TrimLeadingTrailing(DSLink4.NBR))
Also, is there any alternate ways to achieve the same.

NBR is a CHAR column of length 3 and I am converting it to decimal(3,0).I am using the similar derivation for few other columns also.


One more doubt, is there any limit for the constraints as far as memory consumption is considered, can I change that setting?

Thanks in advance,

Ajith

Posted: Fri Nov 10, 2006 8:51 am
by Krazykoolrohit
Check for nulls as well before you enter the constraint. (assuming you are not using this constraint in stage variable.

Code: Select all

If ( TrimLeadingTrailing(DSLink4.DEPN_NBR) = '' ) or ( TrimLeadingTrailing(DSLink4.DEPN_NBR) = NULL ) then 999 else If (Isvalid( "decimal", StringToDecimal(TrimLeadingTrailing(DSLink4.NBR)))=0) then 999 else StringToDecimal(TrimLeadingTrailing(DSLink4.NBR))
As for the memory question, you can use as much memory through datastage as it is available in your server. Datastage does not specify or limit any memory usage