allas
allas copied to clipboard
Hack for SET queries could possibly be removed.
These exceptions to allow some SET queries could possibly be removed if you instead had the JDBC users set the connection parameter assumeMinServerVersion to 9.0 or higher when connecting.
That will cause the JDBC driver to send those parameters in the startup message rather than as SET queries.
https://github.com/pgjdbc/pgjdbc/blob/c8a639edbd0cf39453048f1fd7d9412ec8e09293/pgjdbc/src/main/java/org/postgresql/core/v3/ConnectionFactoryImpl.java#L722
It could possibly be more future proof since the JDBC people are likely to add any other such properties in the same way in the future.
These exceptions to allow some SET queries could possibly be removed if you instead had the JDBC users set the connection parameter assumeMinServerVersion to 9.0 or higher when connecting.
Interesting. I think it would still be valuable to have proper parsing and ignoring of SET queries, but certainly that JDBC option looks juicy. I can bring this up internally.