createQueryBuilder('a') ->andWhere('a.exampleField = :val') ->setParameter('val', $value) ->orderBy('a.id', 'ASC') ->setMaxResults(10) ->getQuery() ->getResult() ; } */ /* public function findOneBySomeField($value): ?Avatar { return $this->createQueryBuilder('a') ->andWhere('a.exampleField = :val') ->setParameter('val', $value) ->getQuery() ->getOneOrNullResult() ; } */ }