DBLINK_ERROR_MESSAGE(3)
β¨ NAME β¨
Okay bestie, welcome to the DBLINK_ERROR_MESSAGE(3) page from the PostgreSQL 16.15 Documentation π
This is all about dblink_error_message β it gets the last error message on the named connection. No cap. π«Ά
π°οΈ SYNOPSIS π°οΈ
dblink_error_message(text connname) returns text
π¬ DESCRIPTION π¬
dblink_error_message fetches the most recent remote error message for a given connection. It's literally giving βwhat went wrong last on this connection?β energy. πΈ
π§ ARGUMENTS π§
connnameβ name of the connection to use. That's the connection you're checking, bestie. π
π RETURN VALUE π
Returns the last error message, or OK if there has been no error in this connection. Simple as that, periodt. β
π¦ NOTES π¦
Lowkey important: when asynchronous queries are initiated by dblink_send_query, the error message associated with the connection might not get updated until the server's response message is consumed. π
This typically means that dblink_is_busy or dblink_get_result should be called prior to dblink_error_message, so that any error generated by the asynchronous query will be visible. Fr fr, check those first so the async error actually shows up. π
π EXAMPLES π
SELECT dblink_error_message('dtest1');
Manual page vibe check complete: source/version is PostgreSQL 16.15, date is 2026. Stay slaying your connections, bestie ππβ¨
π¦ where this page comes from
- opensuse-leap 16.0: postgresql16-docs 16.15-160000.1.1 Β· PostgreSQL
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms