int pg_num_rows ( resource $result )
pg_num_rows() will return the number of rows in a PostgreSQL result resource. Note: This function used to be called pg_numrows().
The number of rows in the result. On error, -1 is returned.