v2.7.0
This is a minor release of Doctrine DBAL that aggregates over 80 fixes and improvements developed over the last 8 months.
This release includes all changes of the 2.6.x
series, as well as feature additions and improvements that couldn't land in patch releases.
Backwards Compatibility Breaks
This release comes with one potential Backwards Compatibility (BC) break that is to be considered during upgrade.
Please see the details below.
Dependency requirement changes
There are no changes in requirements to runtime dependencies.
Deprecations
- Direct usage of
PDO::
constants in calls to DBAL API is deprecated. - Calls to
\PDOStatement
methods on a\Doctrine\DBAL\Driver\PDOStatement
instance are deprecated. - A series of enum-like constants are deprecated.
- Setting unsupported options on a schema column object is deprecated.
Please see details in the UPGRADE.md documentation.
New features
This release introduces the following major additions:
- MariaDB 10.2 platform support
- PostgreSQL 10 platform support
Improvements and Fixes
This release comes with a few bug fixes and a significant set of improvements in continuous integration processes, code style and documentation:
- The code is continuously tested on all supported versions of SQL Server on Windows and Linux.
- The code is tested with lowest compatible versions of dependencies.
- New improved code style requirements have been introduced.
- The codebase has been cleaned up from the fragments required to support the older PHP versions and uses the full power of the PHP 7.1.
- All pull requests are validated for compliance with the coding standards before getting accepted.
- Handling of platform-specific features has been improved.
A detailed list of fixes can be found below.
Total issues resolved: 81
BC Breaks:
Deprecations:
- 2846: Ensure column options map to an existing method thanks to @greg0ire
- 2996: Forward compatibility with 3.x thanks to @morozov
- 2998: Extract some constants into TransactionIsolationLevel, TrimMode and DateIntervalUnit thanks to @Majkl578
New Features:
- 2825: MariaDB 10.2 initial support thanks to @belgattitude
- 2893: PostgreSQL 10 support thanks to @simPod
Bug Fixes:
- 2819: PHP Fatal error: Uncaught Doctrine\DBAL\DBALException: Failed to connect to the database: Invalid platform version "5.5.5-10.1.25-MariaDB thanks to @stfast
- 2868: Doctrine\DBAL\Exception\InvalidFieldNameException when working with DB schema on PostgreSQL 10 thanks to @skobkin
- 2988: renameColumn will changed default from NULL to 'NULL' thanks to @kingshark8848
Improvements:
- 2551: Implement the column collation for Mysql thanks to @mikeSimonson
- 2578: DateIntervalType (negative support) thanks to @galeaspablo
- 2588: Inherit charset from master connection if not set explicitly thanks to @Deltachaos
- 2718: Add iterators for non pdo drivers. thanks to @jenkoian
- 2616: CI testing of MSSQL on windows with AppVeyor thanks to @photodude
- 2617: Testing of MSSQL on Windows with AppVeyor thanks to @photodude
- 2835: Stop relying on Type::__toString thanks to @greg0ire
- 2851: Test default value declaration for the date type thanks to @greg0ire
- 2919: Add tests for column collation to prove it works thanks to @Tobion
- 2952: Enabled testFetchLongBlob() for PDO SQL Server driver thanks to @morozov
- 2954: The IBM DB2 Statement driver suppresses errors triggered by db2_execute thanks to @morozov
- 2955: Removed error suppression in IBM DB2 Statement thanks to @morozov
- 3009: PHPUnit 7 thanks to @carusogabriel
- 3013: Escape LIKE metacharacters thanks to @greg0ire
- 3019: Allow dynamic intervals in DATE_ADD & DATE_SUB for SQLite thanks to @fogs
- 3020: Improve handling of schemas in SQL Server >= 2008 thanks to @stlrnz
- 3031: Connection parameters are cached hashed thanks to @fullbl
Documentation Improvements:
- 2793: Fix articles of words sounding with a consonant (SQL => ESS-kew-ELL) thanks to @afoeder
- 2799: Fix Shard Manager docs with more accurate docblocks in
SQLAzureShardManager
andPoolingShardManager
thanks to @tolbon - 2813: fixed return type into OCI8Statement thanks to @AlessandroMinoccheri
- 2814: Incorrect documentation example for
QueryBuilder#set()
thanks to @Dormilich - 2818: #2814 removing incorrect
QueryBuilder#set()
documentation, which was showing wrong password hashing and value binding practices (combo!) thanks to @Dormilich - 2827: use intended semantics thanks to @greg0ire
- 2840: Proofread types doc thanks to @greg0ire
- 2874: Tenant documentation typos thanks to @phil-davis
- 2875: Doc typos and grammar thanks to @phil-davis
- 2864: Removed the "OCI8: SQL Queries with Question Marks" section thanks to @morozov
- 2935: Improve deprecation wording in
Doctrine\DBAL\Schema\Column#setOptions()
thanks to @greg0ire - 2940: Clean up note on query builder setParameter documentation thanks to @jnvsor
- 3027: Documentation: Warn against using object fields in MySQL and MariaDB thanks to @Jasu
- 3068: typo in known vendor issues documentation thanks to @gdc676463
- 3069: fix typo in known vendor issues documentation thanks to @gdc676463
Continuous Integration Improvements:
- 2801: added badges for continuousphp and other badges for 2.6 thanks to @ppaulis
- 2849: Update build to use stages (adding PHPCS to check for CS violations) thanks to @lcobucci
- 2920: Improve build configuration thanks to @lcobucci
- 2936: Incremental check for coding standards in pull requests thanks to @morozov
- 2946: Attempt to run PostgeSQL 10 on Travis thanks to @Majkl578
- 2956: Travis: Test against lowest and dev dependencies thanks to @Majkl578
- 2961: Code style check fails on develop thanks to @morozov
- 2962: Fixed code style check failures for pull request against non-master branches thanks to @morozov
- 3050: Test SQL Server 17 on Travis thanks to @Majkl578
- 3056: Set Appveyor to use PHP 7.2 thanks to @photodude
- 3062: Added badges for AppVeyor thanks to @morozov
Code Style Improvements:
- 2789: Use short array declarations thanks to @AlessandroMinoccheri
- 2797: Typing final class DriverManager thanks to @tolbon
- 2798: Fix PSR2 rules : "the static declaration should come after visibility" thanks to @tolbon
- 2800: Fix inconsistent/missing return statements thanks to @tolbon
- 2809: Missing @throws declarations in Connection thanks to @bestform
- 2810: add @throws declarations to docs in Connection thanks to @bestform
- 2856: use newer PHP syntax thanks to @AlessandroMinoccheri
- 2857: use newer PHP syntax thanks to @AlessandroMinoccheri
- 2858: Style improvements thanks to @greg0ire
- 2869: fixed typo into security documentation thanks to @AlessandroMinoccheri
- 2927: Refactoring tests thanks to @carusogabriel
- 2932: Refactoring tests thanks to @carusogabriel
- 2934: Use Null Coalesce Operator thanks to @carusogabriel
- 2937: Clean elses thanks to @carusogabriel
- 2942: Combine consecutives unsets thanks to @carusogabriel
- 2957: Whitespaces clean-up in docs thanks to @carusogabriel
- 2965: Update Doctrine CS requirement thanks to @Majkl578
- 2980: Simplify returns thanks to @carusogabriel
- 2999: CS: correct annotation types to use symbols specified in the CS rules thanks to @carusogabriel
- 3002: Use @var instead of @param thanks to @carusogabriel
- 3008: removed an else condition, fixed a parameter annotation and make little improvements thanks to @AlessandroMinoccheri
- 3015: A cast statement must be followed by a single space thanks to @carusogabriel
- 3026: Bump CS version to 3.0 thanks to @Majkl578
- 3077: CS bump to 4.0, imports for global functions & constants thanks to @Majkl578
Chore:
- 2950: Removed pre-7.1 quirks thanks to @Majkl578
- 2989: Update license's copyright thanks to @SenseException
- 3024: Fixed unqualified PDO class name thanks to @morozov
- 3060: Development branch build fails on SQL Server thanks to @morozov
- 3061: Fixed build failure on SQL Server thanks to @morozov
- 3071: Start SQL Server using a synchronous command to avoid intermittent login failures thanks to @morozov