Re: BUG #3659: should use implizit type cast in check constraint

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: BUG #3659: should use implizit type cast in check constraint
Дата
Msg-id 21019.1191859060@sss.pgh.pa.us
обсуждение исходный текст
Ответ на BUG #3659: should use implizit type cast in check constraint  ("Michael Enke" <michael.enke@wincor-nixdorf.com>)
Список pgsql-bugs
"Michael Enke" <michael.enke@wincor-nixdorf.com> writes:
> if I have defined my own data type/operators,
> in a check constraint this type is used
> instead of ::text.

It looks to me like you must have defined an operator =(varchar,testchar)
--- the only way a user-defined type would win over text is to have an
exact match.  This is not a good idea.  Just define =(text,testchar)
and leave it to the implicit coercion code to handle varchar.

            regards, tom lane

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

Предыдущее
От: "Kevin Grittner"
Дата:
Сообщение: Re: BUG #3657: Performance leaks when using between of two equal dates
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: BUG #3619: Renaming sequence does not update its 'sequence_name' field