-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This patch adds support for the PLpgSQL `RAISE` statement. The `RAISE` statement can send messages back to the client during execution, as well as raise a user-specified error. There are a few variations on the syntax, but in general `RAISE` statements have a log level (default `EXCEPTION`), a message (if not specified, the code string is used), and various options: `DETAIL`, `HINT`, `ERRCODE` etc. With log level `EXCEPTION` the error is returned just like any other error, but for other levels it is sent as a notice to the client and flushed synchronously before execution continues. This feature is often used to track progress, since the notices are sent before execution finishes. Fixes #105251 Release note (sql change): Added support for the PLpgSQL `RAISE` statement, which allows sending notices to the client and raising errors. Currently the notice is only sent to the client; support for logging notices is left for future work.
- Loading branch information
1 parent
df37e00
commit 85b7617
Showing
4 changed files
with
2,016 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.