Subject RE: [firebird-support] FB 1.5 RC6: Cannot use rtrim multiple times in the same statement
Author Thomas Steinmaurer
> If I attempt to use the rtrim udf multiple times in the same
> statement as in
> this example
>
> select rtrim(rr.rdb$owner_name),
> rtrim(rr.rdb$relation_name)
> from rdb$relations rr
> where rr.rdb$system_flag = 0;
>
> then I will get this error
>
> Invalid token.
> invalid request BLR at offset 31.
> Implementation limit exceeded.
> block size exceeds implementation restriction.
>
> It will work if one of the "rtrim" references is removed.
>
> Here is my udf registration
>
> declare external function rtrim cstring(32767)
> returns cstring(32767) free_it entry_point 'IB_UDF_rtrim'
> module_name 'ib_udf';
>
> Is this by design?

I guess you are hitting the 64k row size limit with that
UDF declaration when using the UDF in a SELECT two times.
If you don't really need passing such huge parameters,
then declare it with shorter ones (e.g. 256).


--
Best Regards,
Thomas Steinmaurer

The IB LogManager Product Family
Logging/Auditing Suite for InterBase and Firebird
http://www.iblogmanager.com