In MariaDB when we try the show procedure code command to display the function coding but it gives the following error:
Error: The ‘SHOW PROCEDURE|FUNCTION CODE’ feature is disabled; you need MariaDB built with ‘–with-debug’ to have it working
MariaDB [test]> show procedure code sf_escapechars_test;
ERROR 1289 (HY000): The 'SHOW PROCEDURE|FUNCTION CODE' feature is disabled; you need MariaDB built with '--with-debug' to have it working
Solution:
We have to use the following command to show the procedure in MariaDB / MySQL:
Note: \G will help in format
SHOW CREATE PROCEDURE proc_name \G
SHOW CREATE FUNCTION fun_name \G
SELECT * FROM INFORMATION_SCHEMA.ROUTINES WHERE ROUTINE_NAME='run' \G