Does doctrine support named queries ? How do I write named query inside an Entity Class like you do in JPA ?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can define a named query e.g. in the constructor of your *Table class, not the entity class:
Execute this query:
The official documentation has more in depth examples: http://readthedocs.org/docs/doctrine/en/latest/en/manual/dql-doctrine-query-language.html#named-queries