因此,我有关系查询的关系,我只想为表 CancellationRequest c 选择最近创建的记录。
任何人都知道这是否/应该是可能的以及如何?
Doctrine_Query::create()
->from('UserNotificationTo unt')
->leftJoin('unt.Notification un')
->leftJoin('un.QuoteOrder qo')
->leftJoin('qo.CancellationRequest c')
->where('un.sent_external = 0')
->andWhere('c.updated_at *IS THE MOST RECENTLY CREATED ONE*')
->execute();