Symfony2 / Doctrine make $statement->execute() not “buffer” all values

前端 未结 3 1376
滥情空心
滥情空心 2021-02-09 14:06

I\'ve got a basic codeset like this (inside a controller):

$sql = \'select * from someLargeTable limit 1000\';
$em = $this->getDoctrine()->getManager();
$c         


        
3条回答
  •  傲寒
    傲寒 (楼主)
    2021-02-09 14:20

    You can disable query buffer by doctrine config param options

    doctrine:
        dbal:
            # configure these for your database server
            driver: 'pdo_mysql'
            ...
            options:
                1000: false
    

提交回复
热议问题