Bug #78129
closedStatement::rowCount not reliable for SELECT queries
100%
Description
see https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Driver/Statement.php#L127
... taken from the PHPdoc comment:
Returns the number of rows affected by the last DELETE, INSERT, or UPDATE statement
executed by the corresponding object.If the last SQL statement executed by the associated Statement object was a SELECT statement,
some databases may return the number of rows returned by that statement. However,
this behaviour is not guaranteed for all databases and should not be
relied on for portable applications.
In particular rowCount() on valid SELECT statements for SQLite as DBMS returns 0 when fetch() would retrieve existing records. Thus, using rowCount() should be avoided and replaced by proper COUNT statements instead - if required at all.
Updated by Gerrit Code Review about 8 years ago
- Status changed from New to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50083
Updated by Gerrit Code Review about 8 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50083
Updated by Benni Mack about 8 years ago
- Sprint Focus set to Stabilization Sprint
Updated by Gerrit Code Review about 8 years ago
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50083
Updated by Gerrit Code Review about 8 years ago
Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50083
Updated by Morton Jonuschat almost 8 years ago
- Category changed from 999 to Database API (Doctrine DBAL)
Updated by Benni Mack almost 8 years ago
- Target version changed from 8.6 to 8 LTS
Updated by Christian Kuhn over 7 years ago
- Target version deleted (
8 LTS) - Sprint Focus deleted (
Stabilization Sprint)
Updated by Gerrit Code Review over 6 years ago
Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50083
Updated by Gerrit Code Review over 6 years ago
Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50083
Updated by Gerrit Code Review over 6 years ago
Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50083
Updated by Gerrit Code Review over 6 years ago
Patch set 8 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50083
Updated by Gerrit Code Review over 6 years ago
Patch set 9 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50083
Updated by Susanne Moog over 6 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 0367dbda85deb5009671ea8bf0484458a920a7a2.
Updated by Alexander Stehlik over 6 years ago
- Related to Bug #85228: Invalid count query in SuggestWizardDefaultReceiver added
Updated by Georg Ringer over 6 years ago
- Related to Bug #85359: BE-Pagebrowser broken added
Updated by Stephan Großberndt over 6 years ago
- Precedes Bug #85743: An exception occurred if I click on List added
Updated by Daniel Siepmann almost 5 years ago
- Related to Bug #90231: Linkvalidator makes use of rowCount() and does not work with sqlite added
Updated by Sybille Peters almost 5 years ago
What is the status here? This issue is closed but it seems that rowCount() is still a problem with sqlite, see #90231