pgsql: Further tweaking of print_aligned_vertical().

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Further tweaking of print_aligned_vertical().
Date: 2015-12-01 19:47:37
Message-ID: E1a3qtl-000546-Oc@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

Further tweaking of print_aligned_vertical().

Don't force the data width to extend all the way to the right margin if it
doesn't need to. This reverts the behavior in non-wrapping cases to be
what it was in 9.4. Also, make the logic that ensures the data line width
is at least equal to the record-header line width a little less obscure.

In passing, avoid possible calculation of log10(0). Probably that's
harmless, given the lack of field complaints, but it seems risky:
conversion of NaN to an integer isn't well defined.

Branch
------
REL9_5_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/181346cf9892820c94f51525d2c38684148812bf

Modified Files
--------------
src/bin/psql/print.c | 56 ++++++++++++++++++++++--------------
src/test/regress/expected/psql.out | 40 +++++++++++++-------------
2 files changed, 55 insertions(+), 41 deletions(-)

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2015-12-01 21:24:55 pgsql: Make gincostestimate() cope with hypothetical GIN indexes.
Previous Message Robert Haas 2015-12-01 16:56:17 Re: pgsql: postgres_fdw: Add ORDER BY to some remote SQL queries.

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2015-12-01 19:56:00 Re: El Capitan Removes OpenSSL Headers
Previous Message David Fetter 2015-12-01 19:20:54 Re: Another little thing about psql wrapped expanded output