欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  IT编程

在psql中,使用\watch反复查看语句的执行结果

程序员文章站 2022-10-31 22:52:12
test=> \c test a You are now connected to database "test" as user "a&qu...

test=> \c test a

You are now connected to database "test" as user "a".

test=> select * from a.test;

id

----

1

(1 row)

test=> select * from a.test; \watch 1 -----单位为秒

id

----

1

(1 row)

Wed 08 Feb 2017 09:57:04 AM CST (every 1s)

id

----

1

(1 row)

Wed 08 Feb 2017 09:57:05 AM CST (every 1s)

id

----

1

(1 row)

Wed 08 Feb 2017 09:57:06 AM CST (every 1s)

id

----

1

(1 row)

Wed 08 Feb 2017 09:57:07 AM CST (every 1s)

id

----

1

(1 row)