Skip to content

Commit 352a9d7

Browse files
committed
Updated UPGRADE.md for 3.x
1 parent 94e5173 commit 352a9d7

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

UPGRADE.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,37 @@
1+
# Upgrade to DEVELOP
2+
3+
## BC BREAK: the PDO symbols are no longer part of the DBAL API
4+
5+
1. The support of `PDO::PARAM_*`, `PDO::FETCH_*`, `PDO::CASE_*` and `PDO::PARAM_INPUT_OUTPUT` constants in the DBAL API is removed.
6+
2. `\Doctrine\DBAL\Driver\PDOStatement` does not extend `\PDOStatement` anymore.
7+
8+
Before:
9+
10+
use Doctrine\DBAL\Portability\Connection;
11+
12+
$params = array(
13+
'wrapperClass' => Connection::class,
14+
'fetch_case' => PDO::CASE_LOWER,
15+
);
16+
17+
$stmt->bindValue(1, 1, PDO::PARAM_INT);
18+
$stmt->fetchAll(PDO::FETCH_COLUMN);
19+
20+
After:
21+
22+
use Doctrine\DBAL\ColumnCase;
23+
use Doctrine\DBAL\FetchMode;
24+
use Doctrine\DBAL\ParameterType;
25+
use Doctrine\DBAL\Portability\Connection;
26+
27+
$params = array(
28+
'wrapperClass' => Connection::class,
29+
'fetch_case' => ColumnCase::LOWER,
30+
);
31+
32+
$stmt->bindValue(1, 1, ParameterType::INTEGER);
33+
$stmt->fetchAll(FetchMode::COLUMN);
34+
135
# Upgrade to UNRELEASED
236

337
## DEPRECATION: direct usage of the PDO APIs in the DBAL API

0 commit comments

Comments
 (0)