Doctrine orm 如何从多个级别访问DQL查询结果?

Doctrine orm 如何从多个级别访问DQL查询结果?,doctrine-orm,Doctrine Orm,我正在使用DQL进行以下几种连接: SELECT m, c, ct, t FROM Message m JOIN m.classifications c LEFT JOIN c.current_translations ct LEFT JOIN ct.translation t WHERE t.id IS NOT NULL 得到结果后,如何访问ct和t记录? 我可以通过$result->classification访问c记录,但ct和t在哪里 $result->classificatio

我正在使用DQL进行以下几种连接:

SELECT m, c, ct, t FROM Message m 
JOIN m.classifications c 
LEFT JOIN c.current_translations ct 
LEFT JOIN ct.translation t
WHERE t.id IS NOT NULL
得到结果后,如何访问ct和t记录? 我可以通过$result->classification访问c记录,但ct和t在哪里

$result->classification[0]没有当前的\u translation属性,并且*result->current\u translations*不存在,我也尝试了$result->ct,但没有效果

我知道这些关联的存在是因为WHERE子句


如何访问ct和t对象?

结果只是一个常规实体,因此:

$result->getClassifications()[0]->getCurrentTranslations()