|
db2_num_rows(PECL ibm_db2 >= 1.0.0) db2_num_rows — Returns the number of rows affected by an SQL statement Описание
int db2_num_rows
( resource $stmt
)
Returns the number of rows deleted, inserted, or updated by an SQL statement. To determine the number of rows that will be returned by a SELECT statement, issue SELECT COUNT(*) with the same predicates as your intended SELECT statement and retrieve the value. If your application logic checks the number of rows returned by a SELECT statement and branches if the number of rows is 0, consider modifying your application to attempt to return the first row with one of db2_fetch_assoc(), db2_fetch_both(), db2_fetch_array(), or db2_fetch_row(), and branch if the fetch function returns FALSE.
Список параметров
Возвращаемые значенияReturns the number of rows affected by the last SQL statement issued by the specified statement handle. |
|