|
PHP5中文手册
mysqli_stmt_num_rowsstmt->num_rows(No version information available, might be only in CVS) stmt->num_rows — Return the number of rows in statements result set 说明Procedural style :
int mysqli_stmt_num_rows
( mysqli_stmt $stmt
)
Object oriented style (property): mysqli_stmt
int$num_rows;
Returns the number of rows in the result set. The use of mysqli_stmt_num_rows() depends on whether or not you used mysqli_stmt_store_result() to buffer the entire result set in the statement handle. If you use mysqli_stmt_store_result(), mysqli_stmt_num_rows() may be called immediately. 返回值An integer representing the number of rows in result set. 范例Example#1 Object oriented style
<?php Example#2 Procedural style
<?php 上例将输出:
|