Skip to content

Commit 30995e7

Browse files
authored
call fetchAllAssociative for a result set
`fetchAllAssociative()` is not available for class "Doctrine\DBAL\Statement"
1 parent 82bc8cf commit 30995e7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

doctrine.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -848,10 +848,10 @@ In addition, you can query directly with SQL if you need to::
848848
ORDER BY p.price ASC
849849
';
850850
$stmt = $conn->prepare($sql);
851-
$stmt->executeQuery(['price' => $price]);
851+
$resultSet = $stmt->executeQuery(['price' => $price]);
852852

853853
// returns an array of arrays (i.e. a raw data set)
854-
return $stmt->fetchAllAssociative();
854+
return $resultSet->fetchAllAssociative();
855855
}
856856
}
857857

0 commit comments

Comments
 (0)