Re: pgsql: Show opclass and opfamily related information in psql

Поиск
Список
Период
Сортировка
От Alexander Korotkov
Тема Re: pgsql: Show opclass and opfamily related information in psql
Дата
Msg-id CAPpHfdvfkGz=6JbshtMKNcfJc5AsZqW7Dqy=W3u8gfLRgG8qsw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: pgsql: Show opclass and opfamily related information in psql  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Ответы Re: pgsql: Show opclass and opfamily related information in psql  (Nikita Glukhov <n.gluhov@postgrespro.ru>)
Список pgsql-hackers
Hi!

On Tue, May 12, 2020 at 12:09 AM Alvaro Herrera
<alvherre@2ndquadrant.com> wrote:
> On 2020-Mar-08, Alexander Korotkov wrote:
>
> > Show opclass and opfamily related information in psql
> >
> > This commit provides psql commands for listing operator classes, operator
> > families and its contents in psql.  New commands will be useful for exploring
> > capabilities of both builtin opclasses/opfamilies as well as
> > opclasses/opfamilies defined in extensions.
>
> I had chance to use these new commands this morning.

Great, thank you!

> Note how operator for strategy 1 are all together, then strategy 2, and
> so on.  But I think we'd prefer the operators to be grouped together for
> the same types (just like \dAp already works); so I would change the clause
> from:
>   ORDER BY 1, 2, o.amopstrategy, 3;
> to:
>   ORDER BY 1, 2, pg_catalog.format_type(o.amoplefttype, NULL), pg_catalog.format_type(o.amoprighttype, NULL),
o.amopstrategy;

+1

> Also, while I'm going about this, ISTM it'd make sense to
> list same-class operators first, followed by cross-class operators.
> That requires to add "o.amoplefttype = o.amoprighttype DESC," after
> "ORDER BY 1, 2,".  For brin's integer_minmax_ops, the resulting list
> would have first (bigint,bigint) then (integer,integer) then
> (smallint,smallint), then all the rest:

+1

Nikita, what do you think?

------
Alexander Korotkov
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company



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

Предыдущее
От: Amit Kapila
Дата:
Сообщение: Re: COPY, lock release and MVCC
Следующее
От: Nikita Glukhov
Дата:
Сообщение: Re: pgsql: Show opclass and opfamily related information in psql