Re: XML ouput for psql

Поиск
Список
Период
Сортировка
От Merlin Moncure
Тема Re: XML ouput for psql
Дата
Msg-id 303E00EBDD07B943924382E153890E5434A927@cuthbert.rcsinc.local
обсуждение исходный текст
Список pgsql-hackers
Tom Lane wrote:
> A larger point is that this is still a protocol revision; pretending
it
> ain't is just willful obscurantism.  You can tell it's a protocol
revision
> because you will need to rewrite client-side libraries to take
advantage
> of it.  If we try to look the other way and pretend it isn't one, then
> we'll just be incurring pain --- the most obvious pain being that it
> will be hard for those client libraries to tell whether the protocol
> extension is supported or not.

Is it at all worth considering returning an xml document as a scalar?
In most cases when I'm extracting constructed documents from the backend
I would not be using psql to do any processing beyond executing the
query.  Also, if at some point the backend learns to return more complex
documents than simple table mappings, this does not complicate the
protocol or the client libs.

As for schemas, they could be manifestly requested by the query.  For
simplicity, they could be inlined into the document, returned instead of
(think explain...), or as a separate column.

Merlin



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

Предыдущее
От: "Adam Harnett"
Дата:
Сообщение: ...
Следующее
От: terr@terralogic.net
Дата:
Сообщение: talking to postgresql from C/C++