Re: Determine operator from it's function

Поиск
Список
Период
Сортировка
От Jim Nasby
Тема Re: Determine operator from it's function
Дата
Msg-id 55972441.8020001@BlueTreble.com
обсуждение исходный текст
Ответ на Re: Determine operator from it's function  (Heikki Linnakangas <hlinnaka@iki.fi>)
Ответы Re: Determine operator from it's function  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 7/3/15 2:33 AM, Heikki Linnakangas wrote:
> On 07/03/2015 01:20 AM, Jim Nasby wrote:
>> Is there a way to determine the operator that resulted in calling the
>> operator function? I thought fcinfo->flinfo->fn_expr might get set to
>> the OpExpr, but seems it can be a FuncExpr even when called via an
>> operator...
>
> Don't think there is. Why do you need to know?

I'd like to support arbitrary operators in variant. I did initial 
testing and it looked like I was getting an OpExpr in fn_expr, but I 
think that's because I was using a real table to test with. When I do 
something like 'a' < 'b' it looks like the operator gets written out of 
the plan. If that's indeed what's happening is there a hook I could use 
to change that behavior?
-- 
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Data in Trouble? Get it in Treble! http://BlueTreble.com



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

Предыдущее
От: David Rowley
Дата:
Сообщение: Re: PATCH:do not set Win32 server-side socket buffer size on windows 2012
Следующее
От: Peter Geoghegan
Дата:
Сообщение: More work on SortSupport for text - strcoll() and strxfrm() caching