I have problem creating custom getters inside my entity repository
class.
When I call my getter from controller:

$qb = $this->get('doctrine.orm.entity_manager')
    ->getRepository('HelloBundle:Test')
    ->getCustomResults();

I get error:

[...]The method name must start with either findBy or findOneBy!

All magic getters (findBy, findOneBy...) work for me tho.
Example from doctrine page is not working:
http://www.doctrine-project.org/docs/orm/2.0/en/reference/working-with-objects.html#custom-repositories
Can anyone please tell me how to create and use custom and complex
queries in sf2? Maybe repositories files are not proper place?

Regards

-- 
If you want to report a vulnerability issue on symfony, please send it to 
security at symfony-project.com

You received this message because you are subscribed to the Google
Groups "symfony users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en

Reply via email to