Merge pull request #20257 from ambrozt/bugfix/20256-mssql-drop-views

Add support for dropping views in MSSQL server when running migrate/fresh
This commit is contained in:
Stefano D. Mtangoo
2024-09-22 16:38:33 +03:00
committed by GitHub
2 changed files with 2 additions and 0 deletions

View File

@ -7,6 +7,7 @@ Yii Framework 2 Change Log
- Bug #20232: Fix regression introduced in `GHSA-cjcc-p67m-7qxm` while attaching behavior defined by `__class` array key (erickskrauch)
- Bug #20231: Fix regression introduced in #20167 in `yii\validators\FileValidator` (bizley)
- Enh #20247: Support for variadic console controller action methods (brandonkelly)
- Bug #20256: Add support for dropping views in MSSQL server when running migrate/fresh (ambrozt)
2.0.51 July 18, 2024
--------------------

View File

@ -333,6 +333,7 @@ class MigrateController extends BaseMigrateController
$dropViewErrors = [
'DROP VIEW to delete view', // SQLite
'SQLSTATE[42S02]', // MySQL
'is a view. Use DROP VIEW', // Microsoft SQL Server
];
foreach ($dropViewErrors as $dropViewError) {