-
Notifications
You must be signed in to change notification settings - Fork 380
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do not call closeCursor() in prepared statements on TYPO3 8.7 #955
Conversation
Calling `closeCursor()` in prepared statements on TYPO3 8.7 leads to always the first result being returned. In TYPO3 >= 9.5 the calls to closeCursor are correct.
I suppose this is a doctrine/dbal error then in the older versions. |
Yes, suppose so too. Which is definitely not going to be fixed. |
Should we add a comment to the code snippet? As this is different per version (and probably a bug?) this might confuse people in the future. |
Stephan, can you give more information: Could you reproduce this? With which database? Can you link to a resource? This looks like it might be related: doctrine/dbal#2546 As per the source comment, it should be possible to reuse statements after calling closeCursor: https://github.com/doctrine/dbal/blob/v2.5.4/lib/Doctrine/DBAL/Driver/ResultStatement.php#L30 My suggestion would be to make the change as Stephan suggested but add a note with explanation. |
Discussion leading to this pull request: https://typo3.slack.com/archives/C03AM9R17/p1595509409408400 |
@sgrossberndt You can preview the rendered documentation either by:
In this PR, the checks have not run, I do not not why. You should usually see something like this: I will look at your changes. |
If you render locally, the first setup may take some time (e.g. clone GitHub repo, pull Docker container, render etc.), but once you have it setup and do rerendering of changes, it is pretty fast because the results are cached and only the changes are rerendered. |
Thanks for the detailed explanation and for looking into the issue, why there are no running checks for this PR. Maybe because its 8.7 and thus no longer LTS? |
You are right. Thanks for pointing that out, I forgot. The checks run via GitHub actions. The 8.7. branch probably does not contain a . |
Releases: main Resolves: TYPO3-Documentation/Changelog-To-Doc#955
* [TASK] Provide PSR-7 Request in PolicyMutatedEvent #955 Releases: main Resolves: TYPO3-Documentation/Changelog-To-Doc#955 * Update Documentation/ApiOverview/Events/Events/Core/Security/PolicyMutatedEvent.rst Co-authored-by: Chris Müller <2566282+brotkrueml@users.noreply.github.com> * Update Documentation/ApiOverview/Events/Events/Core/Security/PolicyMutatedEvent.rst Co-authored-by: Chris Müller <2566282+brotkrueml@users.noreply.github.com> --------- Co-authored-by: Chris Müller <2566282+brotkrueml@users.noreply.github.com>
Calling
closeCursor()
in prepared statements on TYPO3 8.7 leads to always the first result being returned. In TYPO3 >= 9.5 the calls to closeCursor are correct.