Doc #75404 [Opn->Ver]: Wrong information about return type of ResultSet
| From: | cmb@php.net | Date: | Thu, 19 Oct 2017 11:42:31 +0000 |
| Subject: | Doc #75404 [Opn->Ver]: Wrong information about return type of ResultSet | ||
| References: | 1 | Groups: | php.doc.bugs |
| Request: | Send a blank email to doc-bugs+get-15102@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=75404&edit=1
ID: 75404
Updated by: cmb@php.net
Reported by: ich_bin_sehr_gerne at web dot de
Summary: Wrong information about return type of ResultSet
-Status: Open
+Status: Verified
Type: Documentation Problem
-Package: Documentation problem
+Package: SQLite related
PHP Version: 7.1.10
-Assigned To:
+Assigned To: cmb
Block user comment: N
Private report: N
New Comment:
Indeed, the documentation hints at a potential distinction between queries that
have a result (DQL statements) and resultless queries (DML statements, for
instance). However, this is not (and apparently has) never been implemented.
Actually, you either get an SQLite3Result object or FALSE.
Previous Comments:
------------------------------------------------------------------------
[2017-10-19 03:05:07] ich_bin_sehr_gerne at web dot de
Description:
------------
Hey there,
it appears to me that Sqlite3->query() always returns either "false" (if the query
was started with faulty sql statement) or otherwise an "Object", but never
"true", even if the query was run against an empty database table.
Did I get anything wrong? What is the appropriate way to check if there were any matches in the
results?
Regards, Christoph
---
From manual page: http://www.php.net/sqlite3.query
---
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=75404&edit=1