Re: Bug in either collation docs or code

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Bug in either collation docs or code
Дата
Msg-id 23328.1528429966@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Bug in either collation docs or code  ("David G. Johnston" <david.g.johnston@gmail.com>)
Ответы Re: Bug in either collation docs or code  (Melanie Plageman <melanieplageman@gmail.com>)
Список pgsql-hackers
"David G. Johnston" <david.g.johnston@gmail.com> writes:
> On Thu, Jun 7, 2018 at 4:37 PM, Melanie Plageman <melanieplageman@gmail.com>
> wrote:
>> I thought this would error out because the subquery's result is considered
>> implicit and, in this case, it seems you now have conflicting implicit
>> collations. However, this does not produce an error. What am I missing?

> Data, apparently...I got the same non-error result before inserting a
> record into test1 then I got the expected error.
> Its the function/operator the fails when faced with invalid input, not the
> planner, so the error requires data to provoke.

IIRC this was an intentional decision, made on the grounds that we
can't tell whether the function/operator actually cares about having
a determinate collation or not, so we have to leave it to execution of
that function/operator to complain or not.

If collation had been part of the system design to start with, we'd
probably have insisted on being able to determine this sooner.  But
it wasn't, and when we added it, the ability to throw an error sooner
did not seem worth breaking a lot of third-party code for.

            regards, tom lane


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Add RANGE with values and exclusions clauses to the Window Functions
Следующее
От: Tom Lane
Дата:
Сообщение: Re: config.{guess,sub} updates