Subject | Re: [firebird-support] varchar(2048) holds 1012 |
---|---|
Author | Helen Borrie |
Post date | 2004-01-01T01:35:36Z |
At 04:06 PM 31/12/2003 -0800, you wrote:
higher. You should not be getting an arithmetic error on *storing* a
varchar. Have you tried explicitly casting your values as varchar(2048)?
Are you certain that you are not passing an expression (function call,
etc.) that might be causing the exception? The ib_udf string functions
have a known bug that none of them will accept strings longer than 80
bytes, making them useless for processing longer strings.
It seems this problem would benefit from putting a SQL monitor on the
interface, to see what the application is passing.
/heLen
>Hello,Varchar(2048) should accept 2048 characters and overflow at 2049 or
>
>Using FB 1.0
>
>I have a varchar(2048) that holds only about 1012 actual characters. If I
>try to insert
>more than that It fails with:
>
>First Err: arithmetic exception, numeric overflow, or string truncation
>SqlCode: Arithmetic overflow or division by zero has occurred.
>
>The particular string consisted of numerals "12345670123etc", but of
>course that
>should not make any difference.
>
>Is this to be expected? I am pretty sure that I have other tables with
>varchar(2048)
>which will allow inserts of 2000 chars. Or am I losing my mind :)
higher. You should not be getting an arithmetic error on *storing* a
varchar. Have you tried explicitly casting your values as varchar(2048)?
Are you certain that you are not passing an expression (function call,
etc.) that might be causing the exception? The ib_udf string functions
have a known bug that none of them will accept strings longer than 80
bytes, making them useless for processing longer strings.
It seems this problem would benefit from putting a SQL monitor on the
interface, to see what the application is passing.
/heLen