From: Alvaro Herrera <alvherre@2ndquadrant.com>
To: David Gauthier <davegauthierpg@gmail.com>
Cc: pgsql-general@postgresql.org
Subject: Re: Need text wrapping inside a column to avoid record wrapping (tabular output of 'select')
Date: Wed, 25 Jul 2018 12:52:36 -0400
Message-ID: <20180725165236.w2jxbvetk47c4tjk@alvherre.pgsql> (raw)
In-Reply-To: <CAMBRECAWB6cDuStEP05cMeUi6ZqY7ACosW4--1PEch6P8-1gJQ@mail.gmail.com>
On 2018-Jul-25, David Gauthier wrote:
> Hi:
>
> psql (9.6.7, server 9.1.9) on RHEL6
>
> In order to avoid record wrapping in the tabular output of a "select"
> statement, I need to limit the width of certain columns. For those
> columns, I would like to have text wrapping so as not to lose any
> information (IOW, I don't want to simply truncatate and lose info).
\pset format wrapped
It doesn't break on whitespace though.
$ 999,00 │ Nine hundred ninety nine dollars and z…
│…ero cents
$ 1.000,…│ One thousand dollars and zero cents
… 00 │
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: alvherre@2ndquadrant.com, davegauthierpg@gmail.com
Subject: Re: Need text wrapping inside a column to avoid record wrapping (tabular output of 'select')
In-Reply-To: <20180725165236.w2jxbvetk47c4tjk@alvherre.pgsql>
References: <CAMBRECAWB6cDuStEP05cMeUi6ZqY7ACosW4--1PEch6P8-1gJQ@mail.gmail.com> <20180725165236.w2jxbvetk47c4tjk@alvherre.pgsql>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox