-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix create table if not exists when indexes exist
- Loading branch information
1 parent
d75e426
commit 3bddc85
Showing
8 changed files
with
69 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
<?php | ||
|
||
$forge->createTable('table_name', true); | ||
// gives CREATE TABLE IF NOT EXISTS table_name | ||
// creates table only if table does not exist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
############################# | ||
Upgrading from 4.2.1 to 4.2.2 | ||
############################# | ||
|
||
Please refer to the upgrade instructions corresponding to your installation method. | ||
|
||
- :ref:`Composer Installation App Starter Upgrading <app-starter-upgrading>` | ||
- :ref:`Composer Installation Adding CodeIgniter4 to an Existing Project Upgrading <adding-codeigniter4-upgrading>` | ||
- :ref:`Manual Installation Upgrading <installing-manual-upgrading>` | ||
|
||
.. contents:: | ||
:local: | ||
:depth: 2 | ||
|
||
Mandatory File Changes | ||
********************** | ||
|
||
|
||
Breaking Changes | ||
**************** | ||
|
||
- The method ``Forge::createTable()`` no longer executes a ``CREATE TABLE IF NOT EXISTS``. If table is not found in ``$db->tableExists($table)`` then ``CREATE TABLE`` is executed. | ||
- The method signature of ``Forge::_createTable()`` is deprecated. The ``bool`` ``$ifNotExists`` is no longer used and will be removed in a future release. | ||
|
||
Breaking Enhancements | ||
********************* | ||
|
||
|
||
Project Files | ||
************* | ||
|
||
Numerous files in the **project space** (root, app, public, writable) received updates. Due to | ||
these files being outside of the **system** scope they will not be changed without your intervention. | ||
There are some third-party CodeIgniter modules available to assist with merging changes to | ||
the project space: `Explore on Packagist <https://packagist.org/explore/?query=codeigniter4%20updates>`_. | ||
|
||
.. note:: Except in very rare cases for bug fixes, no changes made to files for the project space | ||
will break your application. All changes noted here are optional until the next major version, | ||
and any mandatory changes will be covered in the sections above. | ||
|
||
Content Changes | ||
=============== | ||
|
||
|
||
All Changes | ||
=========== | ||
|
||
This is a list of all files in the **project space** that received changes; | ||
many will be simple comments or formatting that have no effect on the runtime: | ||
|