Skip to content

Conversation

@sfroemkenjw
Copy link

@sfroemkenjw sfroemkenjw commented Oct 8, 2025

Issue: #36

Please do not use QueryBuilder in constructor as QueryBuilder has state. So, re-usage of QB in same class may lead to side-effects of previous QB run. resetQueryPart was removed from Doctrine IMO because of this.

Also Docs show a warning about that:
https://docs.typo3.org/m/typo3/reference-coreapi/main/en-us/ApiOverview/Database/DoctrineDbal/QueryBuilder/Index.html

Quote:

Never instantiate and initialize the query builder manually using dependency injection or GeneralUtility::makeInstance(), otherwise you will miss essential dependencies and runtime setup.

Nice greetings

Stefan

@github-actions github-actions bot added the stale label Nov 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant