ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jeff Butler" <jeffgbut...@gmail.com>
Subject Re: Strange problems and wrong data on Linux (redhat) not on Windows
Date Tue, 25 Nov 2008 12:12:14 GMT
You can force Abator to generate BigDecimals for these fields with
this configuration setting:

<javaTypeResolver>
  <property name="forceBigDecimals" value="true"/>
</javaTypeResolver>

This might be better in your case as it seems that the UNIX driver has
some difficulty converting BigDecimals to Short or Integer.

Jeff Butler

On Tue, Nov 25, 2008 at 5:27 AM, Corné A <tricae@gmail.com> wrote:
> Ok I tested my but off and here is what I found:
>
> All fields from this database are or CHAR or NUMERIC (see bottom voor META
> info)
> the problematic columns both are NUMERIC without scale
> vdperc DATA_TYPE:2 TYPE_NAME:numeric PRECISION:3 LENGTH:3 SCALE:0 RADIX:0
> NULLABLE:1
> vdmuwe DATA_TYPE:2 TYPE_NAME:numeric PRECISION:6 LENGTH:6 SCALE:0 RADIX:0
> NULLABLE:1
> Abator makes them resp. Short, Integer.
>
> But .... when I change them to BigDecimals the problems do NOT occur.
>
> Ergo: Unix has an influence on the DataType conversion.
>
> Someone has a clue for this unix behaviour?
>
> Thx,
> Corné
>
>
> TABLE_QUALIFIER:null TABLE_OWNER:NOBODY TABLE_NAME:vdprre COLUMN_NAME:relnr
> DATA_TYPE:2 TYPE_NAME:numeric PRECISION:8 LENGTH:8 SCALE:0 RADIX:0
> NULLABLE:1 REMARKS:relatinummer_relnr
>  TABLE_QUALIFIER:null TABLE_OWNER:NOBODY TABLE_NAME:vdprre
> COLUMN_NAME:artgrf DATA_TYPE:2 TYPE_NAME:numeric PRECISION:3 LENGTH:3
> SCALE:0 RADIX:0 NULLABLE:1 REMARKS:groep_financieel
>  TABLE_QUALIFIER:null TABLE_OWNER:NOBODY TABLE_NAME:vdprre
> COLUMN_NAME:vdweek DATA_TYPE:2 TYPE_NAME:numeric PRECISION:6 LENGTH:6
> SCALE:0 RADIX:0 NULLABLE:1 REMARKS:weeknummer________vd
>  TABLE_QUALIFIER:null TABLE_OWNER:NOBODY TABLE_NAME:vdprre
> COLUMN_NAME:vdsort DATA_TYPE:12 TYPE_NAME:char PRECISION:10 LENGTH:10
> SCALE:0 RADIX:0 NULLABLE:1 REMARKS:sortering_________vd
>  TABLE_QUALIFIER:null TABLE_OWNER:NOBODY TABLE_NAME:vdprre
> COLUMN_NAME:vdperc DATA_TYPE:2 TYPE_NAME:numeric PRECISION:3 LENGTH:3
> SCALE:0 RADIX:0 NULLABLE:1 REMARKS:percentage________vd
>  TABLE_QUALIFIER:null TABLE_OWNER:NOBODY TABLE_NAME:vdprre
> COLUMN_NAME:vdmuwe DATA_TYPE:2 TYPE_NAME:numeric PRECISION:6 LENGTH:6
> SCALE:0 RADIX:0 NULLABLE:1 REMARKS:mutatie_week______vd
>
>

Mime
View raw message