Re: pgsql: psql: Improve expanded print output in tuples-only mode

Поиск
Список
Период
Сортировка
От Erik Rijkers
Тема Re: pgsql: psql: Improve expanded print output in tuples-only mode
Дата
Msg-id 9c42f6485613d74886f0b09147b62dfe.squirrel@webmail.xs4all.nl
обсуждение исходный текст
Ответ на pgsql: psql: Improve expanded print output in tuples-only mode  (Peter Eisentraut <peter_e@gmx.net>)
Список pgsql-committers
On Sat, February 9, 2013 06:24, Peter Eisentraut wrote:
> psql: Improve expanded print output in tuples-only mode
>
> When there are zero result rows, in expanded mode, "(No rows)" is
> printed.  So far, there was no way to turn this off.  Now, when
> tuples-only mode is turned on, nothing is printed in this case.
>

Good, that's definitely an improvement.

But can we not remove that empty line alltogether in tuples-only mode?

At the moment:

$ echo '\dt+ diffs*' | psql --tuples-only
 public | diffs_2013_01 | table | aardvark | 8456 kB |
 public | diffs_2013_02 | table | aardvark | 7832 kB |

$

The trailing empty line here makes almost as little sense as in the now amended case where there
are zero rows ...

(Of course, I realise that it's much more likely to break existing scripts, but should we then
keep such illogical things forever at all cost?)


Thanks,

Erik Rijkers

> Branch
> ------
> master
>
> Details
> -------
> http://git.postgresql.org/pg/commitdiff/8ade58a4ea318d0ab8548ab94e49a3b80fdbeb0d
>
> Modified Files
> --------------
> src/bin/psql/print.c |    3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
>
> --
> Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-committers
>




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

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: pgsql: psql: Improve expanded print output in tuples-only mode
Следующее
От: Tom Lane
Дата:
Сообщение: pgsql: Add an example of attaching a default value to an updatable view