when calling a stored procedure in zend framework 2 , it throwing an error message, how can i solve this issue ,
$dbAdapter = $e->getApplication()->getServiceManager()->get('Zend\Db\Adapter\Adapter');
$results = $dbAdapter->query("CALL PROCEDURE_NAME('PARAM1')");
$DataSource = $results->execute();
$Statement = $DataSource->getResource();
$Result = $Statement->fetchAll(\PDO::FETCH_OBJ);
the above code is using to get stored procedure information
getting below error
Statement could not be executed (HY000 - 2014 - Cannot execute queries while other unbuffered queries are active. Consider using PDOStatement::fetchAll(). Alternatively, if your code is only ever going to run against mysql, you may enable query buffering by setting the PDO::MYSQL_ATTR_USE_BUFFERED_QUERY attribute.)