Home > Database > Mysql Tutorial > body text

查询数据库中的存储过程和函数_MySQL

WBOY
Release: 2016-06-01 13:51:45
Original
804 people have browsed it

方法一: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 procedure status; //存储过程

 

 SHOW PROCEDURE STATUS WHERE db='servant_591up' 

 show function status;     //函数

 

查看存储过程或函数的创建代码show create procedure proc_name;show create function func_name;查看视图SELECT * from information_schema.VIEWS   //视图SELECT * from information_schema.TABLES   //表查看触发器方法一:语法:SHOW TRIGGERS [FROM db_name] [LIKE expr]实例:SHOW TRIGGERS/G     //触发器方法二:对INFORMATION_SCHEMA数据库中的TRIGGERS表查询mysql>SELECT * FROM triggers T WHERE trigger_name=”mytrigger” /G
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!