https://github.com/franzose/doctrine-collections-fix-example
https://github.com/franzose/doctrine-collections-fix-example
doctrine doctrine-dbal doctrine-orm postgresql symfony
Last synced: 28 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/franzose/doctrine-collections-fix-example
- Owner: franzose
- License: mit
- Created: 2023-01-16T03:38:55.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2023-02-09T15:50:43.000Z (over 3 years ago)
- Last Synced: 2025-01-03T14:48:37.216Z (over 1 year ago)
- Topics: doctrine, doctrine-dbal, doctrine-orm, postgresql, symfony
- Language: PHP
- Homepage:
- Size: 20.5 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Doctrine Collections Fix Example
This repository is based on [the StackOverflow thread](https://stackoverflow.com/questions/13623285/doctrine-self-referencing-entity-disable-fetching-of-children). By default, Doctrine will trigger an additional database query each time you get another collection of children via the dedicated property. The original solution and my enhancement aim to fix the issue. See the tests for reference.
Check out my post on [Medium](https://medium.com/@franzose/optimizing-onetomany-doctrine-collections-398c782706a2?source=friends_link&sk=9b180ea975be65d7cc39fdb32685817d) or [Habr](https://habr.com/ru/post/715942/) (in Russian).