On 5/20/21 5:32 PM, Adriano dos Santos Fernandes wrote:
Hi!

Currently max. CHAR length is limited to 32767 and max. VARCHAR to 32765.

I didn't found any blocker prevent raising that limits to 65535 and
65533 respectively.

Even not going into details agraid I see one serious problem - ISC API compatibility.
Look at XSQLVAR:

typedef struct
{
    ISC_SHORT   sqltype;            /* datatype of field */
    ISC_SHORT   sqlscale;           /* scale factor */
    ISC_SHORT   sqlsubtype;         /* datatype subtype - currently BLOBs only */
    ISC_SHORT   sqllen;             /* length of data area */

sqllen is 16 bit, and it's signed. I.e. people will see negative lengths if variables in sqlda. I'm afraid at least 99% of software working with sqlda does not check for negative length, and receiving it will cause undefined behavior.

Any idea how to avoid that?




Firebird-Devel mailing list, web interface at 
https://lists.sourceforge.net/lists/listinfo/firebird-devel

Reply via email to