Re: BUG #15002: Unexpected behaviour in psql \r command

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Petr Korobeinikov <pkorobeinikov(at)gmail(dot)com>, pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: BUG #15002: Unexpected behaviour in psql \r command
Date: 2018-01-09 17:58:15
Message-ID: CAKFQuwZ+A4PgyfhRLKFc01TzkO--0ka29JumvWhCtzSGmKySBg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Tue, Jan 9, 2018 at 10:45 AM, PG Bug reporting form <
noreply(at)postgresql(dot)org> wrote:

> Previously (at least in 9.6) previous_buf hasn’t been used for any kinds of
> \e subcommand.
> Now if query_buf is empty previous buffer contents is used.
>

​IIUC the complaint is that it is no longer possible to use \edit​ to
generate a completely empty temporary query that can then be written from
scratch.

The v10 behavior is desirable so that leaves either learning a new idiom to
accomplish your goal or adding something like "\edit -" to explicitly
invoke the desired behavior.

Doing:

# SELECT <enter>
# \edit

Seems reasonably straight forward to get a editor for a newly query instead
of the previous one.

David J.

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Devrim Gündüz 2018-01-09 18:42:25 Re: missing repodata for https://download.postgresql.org/pub/repos/yum/9.6/fedora/fedora-26-x86_64
Previous Message PG Bug reporting form 2018-01-09 17:45:10 BUG #15002: Unexpected behaviour in psql \r command