I have a query that looks like this:
My user entity has a one-to-one relation that looks like this:
/** * @var UserProfile * * @ORM\\OneToOne(targ
According to the reference you can add the optional attribute fetch
fetch
/** * @var UserProfile * * @ORM\OneToOne(targetEntity="UserProfile",mappedBy="user", fetch="LAZY") */ private $userProfile;