Re: Doc patch on psql output formats - Mailing list pgsql-hackers

From Daniel Verite
Subject Re: Doc patch on psql output formats
Date
Msg-id 5d4f10c8-95c8-4c49-89e2-1b9dfe056315@manitou-mail.org
Whole thread Raw
In response to Re: Doc patch on psql output formats  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Doc patch on psql output formats
List pgsql-hackers
    Tom Lane wrote:

> As of HEAD, it's impossible to select latex output format
> at all:
>
> regression=# \pset format latex
> \pset: ambiguous abbreviation "latex" matches both "latex" and
> "latex-longtable"

Oops!

> We could fix that by adding a special case to accept an exact match
> immediately.

Personally I would favor that one, but to me the problem is that
allowing abbreviations doesn't really work well in the long run,
that is, if new format names are going to appear recurringly in the
future.

In interactive mode, tab-completion seems good enough (maybe \pset was
not tab-completed in the past, when abbreviations were initially
implemented?).

In non-interactive mode, anything abbreviated may clash in the future
with another format, so there's a forward-compatibility hazzard that
should motivate to avoid them as well in scripts.


Best regards,
--
Daniel Vérité
PostgreSQL-powered mailer: http://www.manitou-mail.org
Twitter: @DanielVerite


pgsql-hackers by date:

Previous
From: Amit Kapila
Date:
Subject: Re: New function pg_stat_statements_reset_query() to reset statisticsof a specific query
Next
From: Amit Kapila
Date:
Subject: Re: New function pg_stat_statements_reset_query() to reset statisticsof a specific query