When working with Doctrine ORM, the preferred, and probably the easiest, way to work with database queries is to use the Doctrine Query Language or DQL. DQL is a query language for your object model: instead of composing raw SQL with the names of tables and columns, you refer to the names of your PHP classes and fields to fetch or update data.
You can learn more about DQL in the documentation, and, if you haven’t yet, start using it in PhpStorm 2018.3!
(more…)