Mastering Doctrine Relations!

Buy Access

In the part 1 of the Doctrine Tutorial we created a freakin' awesome setup: with Doctrine: entities, queries, migrations and fixtures.

But, we're missing a big, giant, huge, important piece! Database relations! And once you've mastered these, you'll be unstoppable! But... a lot of information out there make Doctrine relations look over-complicated. And actually, they're simple and beautiful, especially with some recent changes in Symfony 4:

  • Generating a ManyToOne relationship (association)
  • The annotations for a relation
  • The OneToMany inverse side of a relation
  • Referencing objects across fixture classes
  • The owning versus inverse sides of a relation
  • Doing magic with the ArrayCollection (Criteria)
  • Querying with Joins
  • ManyToMany Relations
  • Pagination!

Help us bring "The Space Bar" app to the galaxy, with, (inter) stellar database relations. Yep, that's the level of humor you can expect!

Your Guides

Ryan Weaver

Questions? Conversation?

  • 2018-05-30 Knayz

    Angular and RxJs Observables are so sweet! Redux and ngRx will be nice too.

  • 2018-05-30 Alexander Enlund

    okay... Thanks for the fast reply and the recommendations!

  • 2018-05-29 weaverryan

    To add more info, we will definitely do something with API's, and relatively soon. I'd like to do a tutorial about APIPlatform, which is AWESOME. But, we may also do something that sticks a bit more to normal Symfony features.

    About Angular specifically, we do have a React tutorial planned, and may do some Vue stuff in the future. But, Angular is not currently on my radar. However, fortunately, there's nothing really special about using Symfony & any of the front-end frameworks. For authentication, the easiest thing to do is use normal "form login" authentication, then allow your AJAX requests to use the session cookie. Then, it's all just normal API/AJAX requests.

    If you have any other questions, let us know!


  • 2018-05-28 Diego Aguiar

    Hey Alexander Enlund

    I can't give you a release date yet, but we already have a tutorial about forms, it's made on Symfony3, but nothing serious has changed

    And, if you want to learn more about how to customize your form's rendering, then you may also like to watch this tutorial:


  • 2018-05-28 Diego Aguiar

    Hey bob

    At the moment we do not have that course in our plans, but we *do* hear all our customer's suggestions, so, thanks for letting us know what would you like to learn!
    You can check our upcoming tutorials here:

    Have a nice day :)

  • 2018-05-28 Alexander Enlund

    When are forms going to appear?

  • 2018-05-27 bob

    Will there be symfony 4 tutorial on api's and how to use that with angular 5 or 6 ?

  • 2018-05-15 Tech Nomad

    Ok, great! Thanx for the quick reply!

  • 2018-05-15 Victor Bocharsky

    Hey Alexander,

    Very rough approximation - it will be started releasing after "Doctrine & the Database" course, probably on the next week. We also want to start releasing ReactJS course very soon, so these two courses on the way to be released.


  • 2018-05-15 Tech Nomad

    Hey, could you tell something about approximate publishing date? Would be great! Thanx in advance!