Re: Polymorphic arguments and composite types

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Polymorphic arguments and composite types
Дата
Msg-id 25124.1191601799@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Polymorphic arguments and composite types  (Jeff Davis <pgsql@j-davis.com>)
Ответы Re: Polymorphic arguments and composite types  (Jeff Davis <pgsql@j-davis.com>)
Список pgsql-hackers
Jeff Davis <pgsql@j-davis.com> writes:
> You could do something like:
> SELECT * FROM c AS c1, c AS c2 WHERE ARRAY[c1.col1] <@ ANY(SELECT c2.col2);

Good point --- actually he could convert it back to the original
subselect style, as long as he's using the correct operator:

SELECT * FROM c WHERE ARRAY[col1] <@ ANY(SELECT col2 FROM c);

The one-element-array trick seems a bit awkward though.  I wonder
why we don't have an "anyelement <@ anyarray" kind of operator...
        regards, tom lane


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

Предыдущее
От: Jeff Davis
Дата:
Сообщение: Re: Polymorphic arguments and composite types
Следующее
От: Jeff Davis
Дата:
Сообщение: Re: Polymorphic arguments and composite types