Subject | Re: URGENT - CONCATENATION ERROR - BUG |
---|---|
Author | crizoo4712 |
Post date | 2008-01-27T20:21:26Z |
I use the function s t r l e n , not substrlen!!
..and this function has another header: ..cstring(32767)..
but the error still occurs, even when I remove the function-calls.
It's got to do with the concatenation.
As soon as you exceed a stringlength of 255 characters (in this case
the variable TXT), the error occurs.
regards, christoph
--- In firebird-support@yahoogroups.com, "tomkrej" <respektive@...>
wrote:
..and this function has another header: ..cstring(32767)..
but the error still occurs, even when I remove the function-calls.
It's got to do with the concatenation.
As soon as you exceed a stringlength of 255 characters (in this case
the variable TXT), the error occurs.
regards, christoph
--- In firebird-support@yahoogroups.com, "tomkrej" <respektive@...>
wrote:
>
> Hi christoph, this is bug, but this bug is Yours,
>
> let we see the definition of STRLEN function
>
> DECLARE EXTERNAL FUNCTION substrlen
> CSTRING(255), SMALLINT, SMALLINT
> RETURNS CSTRING(255) FREE_IT
> ENTRY_POINT 'IB_UDF_substrlen' MODULE_NAME 'ib_udf';
>
> So if You exceed 255 chars, the function fails, it's OK.
>
> You can write Your own strlen with longer strings.
>
> See You, Tom
>
> > /* THE NEXT COMMAND CAUSES THE ERROR, THE LENGTH OF THE RESULT
> > EXCEEDS 255 CHARACTERS */
> > TXT = TXT || CTX || CAST(NUM AS VARCHAR(8)); LEN = STRLEN(TXT);
> > END
> >
> > regards, christoph
> >
>