Back to course

Doctrine Relations: OneToMany

Symfony 0 to Hero: The Complete 2026 Guide

Bi-directional Relations

When an Article has many Comments, the Article side is OneToMany.

Symfony maker generates the collection methods (addComment, removeComment) for you automatically.