Limit Clause While Fetching Child Records in Doctrine
I have two tables Entity and Message. as each entity can have many messages so it's like parent child relation. I dont want to use doctrine custom query so I am loading entity message like
$this->currentUser = Doctrine_Core::getTable('Entity')->find($entityID);
and then "$currentUser->getMessage()" gives me all messages of that person.
So is there any way to get only few message? let's say 3 message only? How can I use LIMIT claue in this case?
Th开发者_StackOverflowanks
Ali
精彩评论