Re: Domains and type coercion

Поиск
Список
Период
Сортировка
От Thomas Lockhart
Тема Re: Domains and type coercion
Дата
Msg-id 3C99E576.F9E12B01@fourpalms.org
обсуждение исходный текст
Ответ на Domains and type coercion  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Domains and type coercion  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
...
> The problem seems to be that when parse_func looks for "exact match"
> operators, it doesn't consider numeric to be an exact match for mydom.
> So that heuristic fails and we're left with no unique best choice for
> the operator.

Sure. At the moment there is no reason for parse_func to think that
mydom is anything, right?

> I'm not sure if there's anything much that can be done about this.

Something has to be done ;)

> We could treat exact and binary-compatible matches alike (doesn't seem
> good), or put a special case into the operator selection rules to reduce
> domains to their basetypes before making the "exact match" test.
> Neither of these seem real appealing, but if we don't do something
> I think that domains are going to be a big pain in the neck to use.

There could also be an explicit heuristic *after* the exact match
gathering to look for an exact match for domains reduced to their base
types. Is there any reason to look for domains before that?
                    - Thomas


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

Предыдущее
От: "Zeugswetter Andreas SB SD"
Дата:
Сообщение: Re: Function call crashes server
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: Linux/mips compile should not use -mips2