node-tds icon indicating copy to clipboard operation
node-tds copied to clipboard

Fix StreamIndexOutOfBoundsError w/null value (0xFFFF val.length)

Open martijndeh opened this issue 13 years ago • 0 comments

I assume a nullable column with a value's length of 0xFFFF should actually become null (see #33). The length is set based on emptyPossible so that is does not break the logic in the isNull method and returns a null value (instead of an empty string).

I do not know if a length of 0xFFFF should always be null or perhaps only for uint16LE length type or VarChar sql types. I would appreciate it if anyone could check this.

Sorry I don't have any tests.

martijndeh avatar Feb 12 '13 11:02 martijndeh