<返回更多

Mysql内容分页显示

2021-09-14    武汉王老吉
加入收藏

如果select出来的结果集超过几个屏幕,那么前面的结果一晃而过无法看到。使用pager可以设置调用os的more

MySQL> pager more

PAGER set to 'more'

mysql> select * from instance_actions_eventsG

*************************** 1. row ***************************

created_at: 2016-12-18 09:42:07

updated_at: 2016-12-18 09:42:27

deleted_at: NULL

id: 1

event: schedule

action_id: 1

start_time: 2016-12-18 09:42:07

finish_time: 2016-12-18 09:42:27

result: Success

traceback: NULL

deleted: 0

host: NULL

details: NULL

*************************** 2. row ***************************

created_at: 2016-12-18 09:42:07

updated_at: 2016-12-18 09:42:27

deleted_at: NULL

id: 2

event: compute_run_instance

action_id: 1

start_time: 2016-12-18 09:42:00

finish_time: 2016-12-18 09:42:20

result: Success

traceback: NULL

deleted: 0

host: NULL

details: NULL

*************************** 3. row ***************************

created_at: 2016-12-18 09:42:27

updated_at: NULL

deleted_at: NULL

id: 3

event: schedule

action_id: 1

start_time: 2016-12-18 09:42:27

finish_time: NULL

result: NULL

--More--

还原成stdout(取消分屏显示)

mysql> nopager

PAGER set to stdout

声明:本站部分内容来自互联网,如有版权侵犯或其他问题请与我们联系,我们将立即删除或处理。
▍相关推荐
更多资讯 >>>