Subject Repost: Problem with NUMBER
Author Roman Rokytskyy
Uwe,

> > wenn I pass BigDecimals to Firebird through the current cvs
> > version of firebirdsql, I get no proper exception when the passed
> > number is too large.
> > Sometimes the database returns negative numbers (looks like a
> > overflow or something), sometimes there is a
> > TypeConversionException. Any clues?
> > I'd rather expect an SQLException with error code 335544321 or
> > something.

I tried to reproduce bugs you described, but I was not able to model
the situation when database returns negative values (I was just not
able to insert values that cause overflow in database).

TypeConversionError is thrown when you assign BigDecimal to a column
that is not FBBigDecimalField (note, NUMERIC(p, s) with s == 0 is not
FBBigDecimalField, but FBLongField). Type conversion happens before
sending request to database. Therefore you do not get SQLException
with code 335544321 which is exception originated by database server.

Can you give any clue how to reproduce overflow error?

Thanks in advance,
Roman Rokytskyy