<?php
use PHPSnippets\Db\Entity\Test;
/**
* @see http://doctrine-orm.readthedocs.org/en/latest/reference/partial-objects.html
*/
// get Entity partial reference with id 1
$ref = $entityManager->getPartialReference(Test::CLASS, 1);
// Access data returns no values, but its id
dump($ref->id, $ref->name);
^ 1
^ null