mysql查看sp,fun,trigger,view,event的方法

2050阅读 0评论2013-06-08 dba_life
分类:Mysql/postgreSQL

1.查看sp和fun
show procedure status;
show function status;
select `name` from mysql.proc where db = 'your_db_name' and `type` = 'PROCEDURE'
select `name` from mysql.proc where db = 'your_db_name' and `type` = 'FUNCTION' 
详细内容
show create procedure procedure_name
show create function function_name

2.查看trigger
show triggers;
select * from information_schema. TRIGGERS

show triggers like 'test1'; 
show create triggers 触发器名称

3.查看view
show table status where comment='view';

详细内容

Show create view/table 视图名称

4.查看event
show events

show create event 事件名





上一篇:ssh-keygen与ssh-copy-id
下一篇:redis的一些简介