Returns the error message most recently generated by an operation on the connection.
Nearly all libpq functions will set a message for
PQerrorMessage
if they fail. Note that by libpq convention, a nonemptyPQerrorMessage
result can consist of multiple lines, and will include a trailing newline. The caller should not free the result directly. It will be freed when the associated PGconn handle is passed toPQfinish
. The result string should not be expected to remain the same across operations on thePGconn
structure.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(c_ptr), | intent(in) | :: | conn |