Doctrine Collections: ManyToMany, Forms & other Complex Relations
Learn advanced Doctrine relations including ManyToMany associations, querying, mapping, clean URL slugs, syncing sides, orphanRemoval, cascade, counting collections, rendering data, filtering efficiently, complex collection forms, and adding extra data. Master these relationships and get back to work.
What you’ll be learning
With the basic of Doctrine relations behind us, it’s time to dive deeper and get our hands dirty with some real-world, but complex collections. Honestly, this is the hardest part of Doctrine: so let’s get it right:
Creating ManyToMany associations
Querying on ManyToMany relations
Mapping the inverse (collection) side of a relation
(bonus) Using DoctrineExtension for clean URL slugs
Keeping the owning & inverse sides in-sync
Using orphanRemoval to delete items in a collection
Using cascade to save items in a collection
Counting collections in the EXTRA_LAZY way
Rendering relationship data from both sides
Filtering collections efficiently with Criteria (mind will be blown)
Dealing with complex collection forms
Adding “extra” data to the “join table”
Doctrine relationships take a little bit more work to get setup. So let’s master this stuff, setup our relationships to win, and get back to work.
User Reviews
Be the first to review “Doctrine Collections: ManyToMany, Forms & other Complex Relations”
You must be logged in to post a review.


There are no reviews yet.