Re: DatabaseMetaData and Transactions
| От | Tom Lane |
|---|---|
| Тема | Re: DatabaseMetaData and Transactions |
| Дата | |
| Msg-id | 26296.1118199561@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: DatabaseMetaData and Transactions (Oliver Jowett <oliver@opencloud.com>) |
| Ответы |
Re: DatabaseMetaData and Transactions
|
| Список | pgsql-jdbc |
Oliver Jowett <oliver@opencloud.com> writes:
> You're going to have to pass metadata down, or change your queries to
> explicitly cast the parameters in the SQL itself. The driver has exactly
> the same problem as your code does -- with the v3 protocol it needs to
> provide a type for the parameter, but if it's just provided as a string
> the only type it can assume is text..
Is there any chance of a win in passing the type across to the backend
as "unknown", and seeing if the backend can infer something reasonable?
For example given
WHERE int4col = ?
it'd be reasonable to infer the type of the ? symbol as int4, and that
logic has been built into the backend since forever.
regards, tom lane
В списке pgsql-jdbc по дате отправления: