Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign upPassing too much data results in a fatal error #446
Comments
added a commit
that referenced
this issue
Dec 10, 2016
added a commit
that referenced
this issue
Dec 10, 2016
sgrif
referenced this issue
Dec 10, 2016
Merged
Construct error messages properly when libpq returns `NULL` result #541
added a commit
that referenced
this issue
Dec 10, 2016
added a commit
that referenced
this issue
Dec 10, 2016
sgrif
closed this
in
#541
Dec 10, 2016
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
sgrif commentedSep 17, 2016
The largest number of bind parameters a single query can contain is 34464 (1/2 of the value of a short, as it uses a signed integer for the length). Attempting to pass more than that will result in a fatal error, which gives no meaningful information back. However, since we know this case will always occur, we can check for it and bubble up that error.
On SQLite it's a bit more complex, as it's based on the SQLITE_MAX_VARIABLE_NUMBER variable, which is 999 by default, but can change at runtime. I'm fine with just assuming it's 999 for now.