- Debugging is turned off for the function.
- Debugging is turned on for another function with a subsequent SET SESSION DEBUG FUNCTION statement.
- The session terminates.
After you set debugging on for a function and a query invokes the function, the function is passed to the debugger. If a debugger is not active, the query cannot complete until the debugger is started, attaches to session running the query, and allows all instances of the function being debugged to complete.