BC Break Report
| Q |
A |
| BC Break |
yes |
| Version |
2.7 |
Summary
My code spits this: PHP Deprecated: Using a PDO fetch mode or their combination (196610 given) is deprecated and will cause an error in Doctrine DBAL 3.0, so I'm trying to upgrade
This should be the part where my code is unfit:
$stmt->fetchAll(\PDO::FETCH_GROUP|\PDO::FETCH_UNIQUE|\PDO::FETCH_ASSOC)
As suggested in the upgrade.MD, I tried to replace it with this:
$stmt->fetchAll(FetchMode::GROUP|FetchMode::UNIQUE|FetchMode::ASSOCIATIVE)
But it doesn't work, because the FetchMode class doesn't define neither FetchMode::GROUP nor FetchMode::UNIQUE
What am I missing here?
Thanks!
BC Break Report
Summary
My code spits this:
PHP Deprecated: Using a PDO fetch mode or their combination (196610 given) is deprecated and will cause an error in Doctrine DBAL 3.0, so I'm trying to upgradeThis should be the part where my code is unfit:
$stmt->fetchAll(\PDO::FETCH_GROUP|\PDO::FETCH_UNIQUE|\PDO::FETCH_ASSOC)As suggested in the upgrade.MD, I tried to replace it with this:
$stmt->fetchAll(FetchMode::GROUP|FetchMode::UNIQUE|FetchMode::ASSOCIATIVE)But it doesn't work, because the
FetchModeclass doesn't define neither FetchMode::GROUP nor FetchMode::UNIQUEWhat am I missing here?
Thanks!