Обсуждение: Killing output

Поиск
Список
Период
Сортировка

Killing output

От
Dave_Pfaltzgraff@patapsco.com
Дата:



Dave Pfaltzgraff@PATAPSCO
12/26/2000 02:34 PM

If I'm in psql and do something stupid like:

select * from table where date < '12/24/1000';

where I meant to enter >, is there some way to kill the ouput so I don't have to
wait for all the output to complete before I can enter the correct command?

Thanks,
Dave



Re: Killing output

От
Tom Lane
Дата:
Dave_Pfaltzgraff@patapsco.com writes:
> If I'm in psql and do something stupid like:
> select * from table where date < '12/24/1000';
> where I meant to enter >, is there some way to kill the ouput so I
> don't have to > wait for all the output to complete before I can enter
> the correct command?

Recent versions of psql pipe the output through 'more' (or 'less', or
local equivalent) automatically.

If you are running a not-so-recent version, I believe that's still true,
but it may not be default behavior.  See psql docs concerning PAGER
environment variable.

Another possibility is that you have PAGER set to a value that prevents
this from happening (like "cat", say).

            regards, tom lane