Re: org.postgresql.util.PSQLException: ERROR: syntax error at or near "(" when calling org.postgresql.jdbc.PgPreparedStatement.getParameterMetaData

Поиск
Список
Период
Сортировка
От Siddharth Jain
Тема Re: org.postgresql.util.PSQLException: ERROR: syntax error at or near "(" when calling org.postgresql.jdbc.PgPreparedStatement.getParameterMetaData
Дата
Msg-id CAPqV3pQwcW0iNTFsuf-vzoyaKDrxQNPvCmJRBLx-Zs5bKanR8Q@mail.gmail.com
обсуждение исходный текст
Ответ на Re: org.postgresql.util.PSQLException: ERROR: syntax error at or near "(" when calling org.postgresql.jdbc.PgPreparedStatement.getParameterMetaData  (Prasanth <dbadmin@pangburngroup.com>)
Список pgsql-jdbc
Thanks. query was the problem indeed. My mistake.

On Fri, Feb 10, 2023 at 1:33 PM Prasanth <dbadmin@pangburngroup.com> wrote:
Did you check the query being used? Most likely that is where the issue would be.

On 2/10/23 3:26 PM, Siddharth Jain wrote:
Hello,

We are using Postgres 14.4 server and 42.5.2 of org.postgresql:postgresql to connect to it from Java.
We get following exception:
Caused by: org.postgresql.util.PSQLException: ERROR: syntax error at or near "("
  Position: 13
at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2676)
at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2366)
at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:356)
at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:316)
at org.postgresql.jdbc.PgPreparedStatement.getParameterMetaData(PgPreparedStatement.java:1705)
at org.apache.commons.dbcp2.DelegatingPreparedStatement.getParameterMetaData(DelegatingPreparedStatement.java:162)
at org.apache.commons.dbcp2.DelegatingPreparedStatement.getParameterMetaData(DelegatingPreparedStatement.java:162)
at cdao.dpde.InsertHelper.setParameters(InsertHelper.java:53)
where the code in the last line is:
ParameterMetaData parameterMetaData = query.getParameterMetaData();

How can we fix this?

S.

В списке pgsql-jdbc по дате отправления:

Предыдущее
От: "David G. Johnston"
Дата:
Сообщение: Re: org.postgresql.util.PSQLException: ERROR: syntax error at or near "(" when calling org.postgresql.jdbc.PgPreparedStatement.getParameterMetaData
Следующее
От: "renovate[bot]"
Дата:
Сообщение: [pgjdbc/pgjdbc] e0317c: chore: Add Renovate configuration for dependency u...