summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrey Andreev <narf@bofh.bg>2012-02-13 11:25:42 +0100
committerAndrey Andreev <narf@bofh.bg>2012-02-13 11:25:42 +0100
commit8ad2ec7b0a8e6ea385b13ad2fd782fe775ef92db (patch)
tree51a6802f5d408b217187fe975f45c13d6e3f8871
parent45ba4f73a13660fa05f30d2ec21965620b0e5be5 (diff)
Fix issue #1036
-rw-r--r--system/database/DB_driver.php2
-rw-r--r--user_guide_src/source/changelog.rst1
2 files changed, 2 insertions, 1 deletions
diff --git a/system/database/DB_driver.php b/system/database/DB_driver.php
index 30149193a..a3171e395 100644
--- a/system/database/DB_driver.php
+++ b/system/database/DB_driver.php
@@ -627,7 +627,7 @@ class CI_DB_driver {
*/
public function is_write_type($sql)
{
- return (bool) preg_match('/^\s*"?(SET|INSERT|UPDATE|DELETE|REPLACE|CREATE|DROP|TRUNCATE|LOAD DATA|COPY|ALTER|GRANT|REVOKE|LOCK|UNLOCK)\s+/i', $sql);
+ return (bool) preg_match('/^\s*"?(SET|INSERT|UPDATE|DELETE|REPLACE|CREATE|DROP|TRUNCATE|LOAD DATA|COPY|ALTER|RENAME|GRANT|REVOKE|LOCK|UNLOCK)\s+/i', $sql);
}
// --------------------------------------------------------------------
diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst
index 66a707e24..caf4a5ca2 100644
--- a/user_guide_src/source/changelog.rst
+++ b/user_guide_src/source/changelog.rst
@@ -105,6 +105,7 @@ Bug fixes for 3.0
- Fixed a bug (#154) - ``CI_Session::sess_update()`` caused the session to be destroyed on pages where multiple AJAX requests were executed at once.
- Fixed a possible bug in ``CI_Input::is_ajax_request()`` where some clients might not send the X-Requested-With HTTP header value exactly as 'XmlHttpRequest'.
- Fixed a bug in CI_DB_driver::version() where it failed when using a database driver that needs to run a query in order to get the version.
+- Fixed a bug (#1036) - Database method is_write_type() didn't match RENAME statements.
Version 2.1.0
=============