Getting name of the current function inside of the function with plpgsql

前端 未结 3 1337
北荒
北荒 2021-01-17 16:28

Is there anyway from within a plpgsql function that you can get the name of the function? Or even the OID of the function?

I know there are some \"special\" variab

3条回答
  •  情深已故
    2021-01-17 16:59

    Update: possibility to take call stack is available in PostgreSQL 9.4

    No, there is no way how to get name of currently executed function in plpgsql function.

    Some year ago I wrote functions for access to call stack - it is part of orafce. You can get last function from stack

提交回复
热议问题