Skip to content

Commit

Permalink
ADODB_FETCH_DEFAULT should be treated as ASSOC
Browse files Browse the repository at this point in the history
Ensures that the recordset is returned in the default provided by the
PHP driver as per the documentation.

Fixes #886
  • Loading branch information
mnewnham authored and dregad committed Nov 23, 2022
1 parent bb87e83 commit 35ea1f5
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions adodb.inc.php
Expand Up @@ -4273,9 +4273,7 @@ function getAssoc($force_array = false, $first2cols = false)
switch ($showArrayMethod) {
case 0:

if ($fetchMode == ADODB_FETCH_ASSOC
|| $fetchMode == ADODB_FETCH_BOTH)
{
if ($fetchMode != ADODB_FETCH_NUM) {
/*
* The driver should have already handled the key
* casing, but in case it did not. We will check and force
Expand Down

0 comments on commit 35ea1f5

Please sign in to comment.