Allow default \watch interval in psql to be configured

From: Daniel Gustafsson <daniel(at)yesql(dot)se>
To: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Allow default \watch interval in psql to be configured
Date: 2024-10-09 13:08:52
Message-ID: B2FD26B4-8F64-4552-A603-5CC3DF1C7103@yesql.se
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Scratching an old itch; I've long wanted to be able to set the default interval
for \watch in psql since I almost never want a 2 second wait. The interval can
of course be set by passing it to \watch but it's handy during testing and
debugging to save that with just quick \watch.

The attached adds a new variable, WATCH_INTERVAL, which is used as the default
value in case no value is defined when executing the command. The defualt of
this remains at 2 seconds as it is now. The count and min_rows values are not
affected by this as those seem less meaningful to set defaults on.

--
Daniel Gustafsson

Attachment Content-Type Size
0001-Make-default-watch-interval-configurable.patch application/octet-stream 5.9 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2024-10-09 13:15:12 Re: NOT ENFORCED constraint feature
Previous Message Antonin Houska 2024-10-09 12:56:17 Re: why there is not VACUUM FULL CONCURRENTLY?