Re: \s paging? - Mailing list pgsql-general

From Bruce Momjian
Subject Re: \s paging?
Date
Msg-id 200403271802.i2RI29O09934@candle.pha.pa.us
Whole thread Raw
In response to \s paging?  (CSN <cool_screen_name90001@yahoo.com>)
List pgsql-general
CSN wrote:
> Is it possible to have "less"-type paging with psql's
> \s command? Or other ways like display the last 50
> commands backwards?

I just checked and the \s code actually calls the readline library:

            if (write_history(fname) == 0)

with fname set to /dev/tty if file name is supplied.  The only fix we
could do would be to put a temp file in for fname, then output that
through a pager.  However, it doesn't seem worth the trouble.

I added a comment in the C code if we ever come back to it.

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Index usage for BYTEA column in OR/IN clause
Next
From: Bruce Momjian
Date:
Subject: Re: Native Win32 port - PLEASE!