Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP


Nullable varchar columns with null values is throwing index out of bounds exception. #33

tdarsan opened this Issue · 0 comments

1 participant


Deletion of this line, as part of #12, in file is causing issues with nullable varchar columns and is throwing index out of bounds exception. Eg:- a varchar(9) nullable column with null values in it will thow an exception.

if val.length is 0xFFFF then val.length = -1

@martijndeh martijndeh referenced this issue from a commit in martijndeh/node-tds
@martijndeh martijndeh Update src/
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.

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.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.