Re: [HACKERS] create operator problem

Поиск
Список
Период
Сортировка
От Tom Ivar Helbekkmo
Тема Re: [HACKERS] create operator problem
Дата
Msg-id 86ra2nql70.fsf@barsoom.Hamartun.Priv.NO
обсуждение исходный текст
Ответ на create operator problem  ("Vazsonyi Peter[ke]" <neko@kornel.szif.hu>)
Список pgsql-hackers
"Vazsonyi Peter[ke]" <neko@kornel.szif.hu> writes:

> drop operator ~~ (text,text);
> DROP
> create operator ~~ (leftarg=text,rightarg=text,procedure=mylike);
> CREATE
> select 'this will be true'::text ~~ 'true';
> ?column?
> --------
> f
> (1 row)
> -- it seems not ;(

I got bitten by this, too.  There's special handling of ~~ hardcoded
into the parser, which expects that it implements the vanilla flavor
of likeness testing.  It has to do with enabling the use of indices to
speed up the matching.  Bottom line: you can't redefine it.

-tih
--
Popularity is the hallmark of mediocrity.  --Niles Crane, "Frasier"

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

Предыдущее
От: Byron Nikolaidis
Дата:
Сообщение: Re: [HACKERS] Re: [INTERFACES] retrieving varchar size
Следующее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] Re: [INTERFACES] retrieving varchar size