Re: xpath processing brain dead

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: xpath processing brain dead
Дата
Msg-id 49A70170.4030506@dunslane.net
обсуждение исходный текст
Ответ на Re: xpath processing brain dead  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: xpath processing brain dead
Re: xpath processing brain dead
Re: xpath processing brain dead
Список pgsql-hackers

Robert Haas wrote:
> But the change you're proposing seems like
> it could CONCEIVABLY break a working application that counts on
> PostgreSQL's particular flavor of misbehavior, and therefore it seems
> questionable to put that into a stable branch.  The fact that the
> application perhaps should not have been written that way to begin
> with is neither here nor there.  We don't want people to be afraid of
> upgrading to the latest point release when we fix, say, a backend
> crash or a data corruption bug.
>
>
>   

Let me reiterate the changes that I propose, and again challenge you to 
provide a working counter-example if you believe it will break anything 
not currently broken, even cases involving fragments.

First, I propose that we abandon this mangling, if, and only if, the xml 
is in fact a well formed XML document. Since the whole point of the 
mangling is to handle situations where the XML is not a well formed 
document, that seems fairly straight-forward. If this change were to 
upset any user, it must be because they are relying on undisputably 
incorrect results.

Second, I propose that, in the remaining cases, where we do mangle the 
XML, if the xpath expression does not begin with a '/', instead of 
prepending it with '/x/, which can not possibly be correct under any 
circumstance, we prepend it with '/x//' which has some possibility of 
giving correct results.

IOW, these proposals will expand the number of correct results from the 
code, without contributing any new incorrect cases. These changes are 
*very* conservative, as is usual when we fix things on stable branches.

cheers

andrew


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

Предыдущее
От: "Joshua D. Drake"
Дата:
Сообщение: Re: xpath processing brain dead
Следующее
От: Andrew Dunstan
Дата:
Сообщение: Re: xpath processing brain dead