Re: controlling psql's use of the pager a bit more

From: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: controlling psql's use of the pager a bit more
Date: 2014-11-13 18:07:57
Message-ID: CAMkU=1xXzHqGmBAHqXhqPk2X6qMi0M+iP4Q-nJKRypFa0BCqzQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Nov 13, 2014 at 7:52 AM, Andrew Dunstan <andrew(at)dunslane(dot)net> wrote:

>
> I often get annoyed because psql is a bit too aggressive when it decides
> whether to put output through the pager, and the only way to avoid this is
> to turn the pager off (in which case your next query might dump many
> thousands of lines to the screen). I'd like a way to be able to specify a
> minumum number of lines of output before psql would invoke the pager,
> rather than just always using the terminal window size.
>

+1.

If it scrolls 2 or 3 lines off the top, I can just use the scroll-back
buffer to look at them, I don't want the pager for that situation.

But I am more interested in width, not length. I don't want it to switch
to the pager just because a couple lines would wrap, especially when
looking at EXPLAIN output. I have played with changing \pset columns, but
then other things get screwy once you set that to a non-actual value. I
don't recall of the top of my head which things those are, though.

Cheers,

Jeff

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jeff Janes 2014-11-13 18:26:07 Re: controlling psql's use of the pager a bit more
Previous Message David Johnston 2014-11-13 18:03:31 Re: controlling psql's use of the pager a bit more