salix/db/routines/util/procedures/proc_restorePrivs.sql

16 lines
405 B
MySQL
Raw Normal View History

DELIMITER $$
CREATE OR REPLACE DEFINER=`root`@`localhost` PROCEDURE `util`.`proc_restorePrivs`()
BEGIN
/**
* Restores the privileges saved by proc_savePrivs().
* This procedure should be called after modifying a procedure,
* for more info see proc_savePrivs().
*/
INSERT IGNORE INTO mysql.procs_priv
SELECT * FROM proc_privs;
FLUSH PRIVILEGES;
DROP TEMPORARY TABLE proc_privs;
END$$
DELIMITER ;