note 115230 deleted from function.sqlite-num-rows by cmb
| From: | cmb@php.net | Date: | Mon, 02 Nov 2020 15:01:43 +0000 |
| Subject: | note 115230 deleted from function.sqlite-num-rows by cmb | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-215747@lists.php.net to get a copy of this message | ||
Note Submitter: rezaamya at gmail dot com
----
neither of "sqlite_num_rows($result)" and "$result->numRows()" is not working
on SQLite3 !
you should use this way:
$db = new SQLite3('databasename.db');
$result = $db->query("SELECT * FROM users");
$rows = count ($result);
echo "Number of rows: $rows";