Re: psql and readline - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: psql and readline
Date
Msg-id Pine.LNX.4.44.0301152043280.789-100000@localhost.localdomain
Whole thread Raw
In response to Re: psql and readline  (Eric B.Ridge <ebr@tcdi.com>)
List pgsql-hackers
Eric B.Ridge writes:

> What about expanding the history capabilities of psql's history command
> (\s) to include something more bash/tcsh-like?  For example:
>     !insert
>        -- execute the last command that began with "insert"
>     !23
>        -- execute item #23 in my history

If you peruse the documentation of the readline and history libraries you
should find that those features already exist.  For example, you can use
C-r and C-s to search through the history.  AFAIK, bash just uses readline
as is, so anything that works there should work for psql as well.

-- 
Peter Eisentraut   peter_e@gmx.net



pgsql-hackers by date:

Previous
From: Justin Clift
Date:
Subject: Re: Anyone have a fresh Solaris 8 SPARC system to create
Next
From: Peter Eisentraut
Date:
Subject: Re: SQL flagger