query($update);有什么函数能够得到这个结果集中的行数?------解决方案--------------------"/> query($update);有什么函数能够得到这个结果集中的行数?------解决方案--------------------">

php sqlite,该怎么处理

WBOY
Release: 2016-06-13 13:31:46
Original
819 people have browsed it

php sqlite
php sqlite数据库查询这样写的:

$db = new SQLite3('my.db');
$update="select * from good";
$result = $db->query($update);

有什么函数能够得到这个结果集中的行数?

------解决方案--------------------
php_sqlite3 提供了3个类
分别提供了
print_r(get_class_methods('sqlite3'));
print_r(get_class_methods('SQLite3Result'));
print_r(get_class_methods('SQLite3Stmt'));
这些方法

似乎没有取得结果集中的行数的方法
但 SQLite3Result 类或许提供了结果集行数的属性,你可以看一下

实在没有就 count(*) 一下

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!