1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-30 11:03:19 +03:00

Add \watch [SEC] command to psql.

This allows convenient re-execution of commands.

Will Leinweber, reviewed by Peter Eisentraut, Daniel Farina, and Tom Lane
This commit is contained in:
Tom Lane
2013-04-04 19:56:33 -04:00
parent e75feb2834
commit c6a3fce7dd
4 changed files with 145 additions and 2 deletions

View File

@ -2478,6 +2478,18 @@ testdb=&gt; <userinput>\setenv LESS -imx4F</userinput>
</varlistentry>
<varlistentry>
<term><literal>\watch [ <replaceable class="parameter">seconds</replaceable> ]</literal></term>
<listitem>
<para>
Repeatedly execute the current query buffer (like <literal>\g</>)
until interrupted or the query fails. Wait the specified number of
seconds (default 2) between executions.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><literal>\x [ <replaceable class="parameter">on</replaceable> | <replaceable class="parameter">off</replaceable> | <replaceable class="parameter">auto</replaceable> ]</literal></term>
<listitem>