-
Notifications
You must be signed in to change notification settings - Fork 219
Error using NUMERIC columns with PreparedStatements in PostgreSQL #164
Conversation
Signed-off-by: Joern Bernhardt <jb@campudus.com>
Here is the relevant stacktrace as travis logs it:
The strange thing is that this only happens when updating with an integer value first and setting it to something different later. |
This is weird, thanks @Narigo, gonna check it out! |
Here is a bit more investigation from psql. Most of the time it works, when using prepared statement, but there is one corner case: If you use
Hope this helps to fix this weird bug :) Thanks @mauricio ! |
@mauricio when you have debug level on, you can see, that there are different values for the types when running the tests included in this PR locally. I've never looked into the PostgreSQL binary protocol, so I'm unsure how else I can help here and if this is a bug in your implementation or if it might even be a bug in PostgreSQL (using the first occurred type inside a prepared statement?)... |
Error using NUMERIC columns with PreparedStatements in PostgreSQL
I fixed/reverted this in jasync-sql(fork) 0.8.30: jasync-sql/jasync-sql#16 . more details in the issue: jasync-sql/jasync-sql#15 |
When using
NUMERIC
columns, updating them with an integer value at first and updating it with a floating number later, an exception is thrown. It looks like this happens withPreparedStatements
only and I couldn't reproduce it on the database directly using IntelliJ database console.See the Spec in the PR for a reproducer of this issue.