Re: PREPARE and parameter types (Re: [INTERFACES] DBD::PostgreSQL)
От | Tom Lane |
---|---|
Тема | Re: PREPARE and parameter types (Re: [INTERFACES] DBD::PostgreSQL) |
Дата | |
Msg-id | 28886.1037773665@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: PREPARE and parameter types (Re: [INTERFACES] DBD::PostgreSQL) (Neil Conway <neilc@samurai.com>) |
Список | pgsql-hackers |
Neil Conway <neilc@samurai.com> writes: > Fair enough -- although there's a major difference between the > meta-data stored about tables (which are permanent database objects > and are typically complex), and prepared statements (which (at > present) are only stored for the duration of the current connection, > and are relatively simple: many statements will not have more than a > couple params). Arguably, the difference is enough to make it > nonessential that we provide client programmers with that information. I forgot to point out this: if the client programmer could conveniently provide that info, we'd not be having this discussion, because he could just as well include the datatypes in the PREPARE command to meet our existing syntax. The fact that we are getting complaints about the syntax is sufficient evidence that it's not always reasonable to expect client-side code to know the datatypes. (I think this comes mainly from the fact that client-side code is not monolithic but tends to consist of multiple layers. Some of those layers may be expected to know a-priori what datatypes a query involves, but others will not know.) regards, tom lane
В списке pgsql-hackers по дате отправления: