Returns the number of rows affected by the SQL command.
This function returns a string containning the number of rows affected by the SQL statement that generated the
PGresult
. This function can only be used following the execution of aSELECT
,CREATE
,TABLE AS
,INSERT
,UPDATE
,DELETE
,MERGE
,MOVE
,FETCH
, orCOPY
statement, or anEXECUTE
of a prepared query that contains anINSERT
,UPDATE
,DELETE
, orMERGE
statement. IF the command that generated thePGresult
was anything else,PQcmdTuples
returns an empty string. The caller should not free the return value directly. It will be freed when the associatedPGresult
handle is passed to PQclear.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(c_ptr), | intent(in) | :: | pgresult |