-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[1.22.0] Parameter value type has changed. #90
Comments
Hi @gomachssm, the reason for this is that pg8000 now lets PostgreSQL determine the parameter types from the query, rather than pg8000 choosing them from the parameter type. So for your query:
PostgreSQL assumes a parameter type of
similarly with your query:
PostgreSQL is guessing that the parameter is of type
|
Hi @tlocke , thank you for answer. I see, use cast in SQL. Why was this fix necessary? |
Sorry this version is working well for you @gomachssm, for a lot of people they're doing queries on a table, so something like:
which gives the output
which gives the output |
Hi @tlocke , thank you for your reply! I see. I found that there was a problem with my usage. |
Hello,
The execution result changed between 1.21 and 1.22.
At v1.21,
([1],)
.At v1.22,
(['1'],)
.The parameter type is
int
, but the return type isstr
.There is another one.
At v1.21,
([datetime.datetime(2021, 1, 2, 4, 4)],)
.At v1.22, raise
pg8000.dbapi.ProgrammingError
in cur.execute().Error log
Am I having problem using it?
The text was updated successfully, but these errors were encountered: