Re: [PATCH] Add pretty-printed XML output option
От | Nikolay Samokhvalov |
---|---|
Тема | Re: [PATCH] Add pretty-printed XML output option |
Дата | |
Msg-id | CANNMO+Kix1DRRa7m4o07qgRHh=0vOiO_x+_PsHOkQvT4GgLrLA@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: [PATCH] Add pretty-printed XML output option (Jim Jones <jim.jones@uni-muenster.de>) |
Ответы |
Re: [PATCH] Add pretty-printed XML output option
|
Список | pgsql-hackers |
On Mon, Feb 20, 2023 at 3:06 PM Jim Jones <jim.jones@uni-muenster.de> wrote:
As suggested by Peter and Nikolay, v15 now removes the xmlformat
function from the catalog and adds the [NO] INDENT option to
xmlserialize, as described in X069.\
Great. I'm checking this patch and it seems, indentation stops working if we have a text node inside:
xmlserialize
----------------------------------------
<?xml version="1.0" encoding="UTF-8"?>+
<xml> +
<more>13</more> +
</xml> +
(1 row)
gitpod=# select xmlserialize(document '<xml>text<more>13</more></xml>' as text indent);
xmlserialize
----------------------------------------
<?xml version="1.0" encoding="UTF-8"?>+
<xml>text<more>13</more></xml> +
(1 row)
Worth to mention, Oracle behaves similarly -- indentation doesn't work: https://dbfiddle.uk/hRz5sXdM.
But is this as expected? Shouldn't it be like this:
<xml>
text
<more>13</more>
</xml>
?
В списке pgsql-hackers по дате отправления: