Bug #36105 Request for CURRENT_PROCEDURE() function
Submitted: 16 Apr 2008 0:03 Modified: 16 Apr 2008 11:14
Reporter: Ondra Zizka Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Stored Routines Severity:S4 (Feature request)
Version: OS:Any
Assigned to: CPU Architecture:Any
Tags: current procedure, FUNCTION, SP, stored procedure

[16 Apr 2008 0:03] Ondra Zizka
Description:
For the purposes of debugging and logging in stored procedures, such function would be very useful:

CURRENT_ROUTINE()
Returns name of the procedure/function from which it was called, or NULL if called in an expression outside a routine.

How to repeat:
CREATE PROCEDURE WhereAmI() BEGIN
  SELECT CURRENT_ROUTINE();
END $$
[16 Apr 2008 11:14] MySQL Verification Team
Thank you for the bug report.