Re: [HACKERS] Re: proposal - psql: possibility to specify sort fordescribe commands, when size is printed - Mailing list pgsql-hackers

From Pavel Stehule
Subject Re: [HACKERS] Re: proposal - psql: possibility to specify sort fordescribe commands, when size is printed
Date
Msg-id CAFj8pRBkUgzY9VB+yjAEhXfHmc27bf9KJUnSNHD2OPMci+dMWQ@mail.gmail.com
Whole thread Raw
In response to Re: [HACKERS] Re: proposal - psql: possibility to specify sort fordescribe commands, when size is printed  (Alexander Korotkov <a.korotkov@postgrespro.ru>)
Responses [HACKERS] Re: proposal - psql: possibility to specify sort for describecommands, when size is printed  (David Steele <david@pgmasters.net>)
Re: [HACKERS] Re: proposal - psql: possibility to specify sort fordescribe commands, when size is printed  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
Re: Re: proposal - psql: possibility to specify sort fordescribe commands, when size is printed  (Andres Freund <andres@anarazel.de>)
List pgsql-hackers


2017-03-10 15:45 GMT+01:00 Alexander Korotkov <a.korotkov@postgrespro.ru>:
On Fri, Mar 10, 2017 at 5:10 PM, Peter Eisentraut <peter.eisentraut@2ndquadrant.com> wrote:
On 2/24/17 16:32, Pavel Stehule wrote:
>     set EXTENDED_DESCRIBE_SORT size_desc
>     \dt+
>     \l+
>     \di+
>
>     Possible variants: schema_table, table_schema, size_desc, size_asc

I can see this being useful, but I think it needs to be organized a
little better.

Sort key and sort direction should be separate settings.
 
I agree.

I'm not sure why we need to have separate settings to sort by schema
name and table name.

I think sorting by schema name, object name makes sense for people, who have objects of same name in different schemas.

I am sending a updated version with separated sort direction in special variable

There is a question. Has desc direction sense for columns like schema or table name?

Using desc, asc for size is natural. But for tablename?

Regards

Pavel

 

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

Attachment

pgsql-hackers by date:

Previous
From: Pavel Stehule
Date:
Subject: Re: [HACKERS] Explicit subtransactions for PL/Tcl
Next
From: Alvaro Herrera
Date:
Subject: Re: [HACKERS] make check-world output