Вилен Тамбовцев <v.tambovtsev@outlook.com> writes:
> Any news on this bug? 9.4 still behaves wrong and this actively stops us from using Postgresql as a storage for our
xmldocs.
AFAICS the conclusion in that thread was that the current behavior is
correct; in particular xpath()'s output is still XML and so it must not
de-escape anything.
http://www.postgresql.org/message-id/72DA66D9-0222-4888-AF55-61D3337CAC7A@phlo.org
regards, tom lane