查看用户连接信息
select datname,usename,client_addr,client_port,pid,state from sys_stat_activity;
select connections();
查看锁表监控
select database,relation,sc.relname,pid,mode,granted from sys_locks sl
left join sys_database sd on sl.database=sd.oid
left join sys_class sc on sl.relation=sc.oid
where sys_backend_pid()<>sl.pid and granted='f';
杀掉锁信息
select sys_terminate_backend(2342) from sys_stat_activity;
查看数据库IO统计信息
select * from sys_stat_database;
标签:stat,database,pid,kingbase,sys,日常,sl,维护,select
From: https://www.cnblogs.com/zbc230/p/17639021.html