summaryrefslogtreecommitdiffstats
path: root/system/database/drivers/mssql/mssql_driver.php
diff options
context:
space:
mode:
authorAndrey Andreev <narf@bofh.bg>2012-11-06 11:48:32 +0100
committerAndrey Andreev <narf@bofh.bg>2012-11-06 11:48:32 +0100
commit083e3c8d39a4fb9f8ef37f61f0ea42ec3fe1389f (patch)
tree5a3d50a32b9ef1cd3fb7afa473a11d48a3099620 /system/database/drivers/mssql/mssql_driver.php
parentbdd9c118c6e04ec8dc9b6bb1a2fb8a39214dca72 (diff)
Fix #589
Diffstat (limited to 'system/database/drivers/mssql/mssql_driver.php')
-rw-r--r--system/database/drivers/mssql/mssql_driver.php23
1 files changed, 23 insertions, 0 deletions
diff --git a/system/database/drivers/mssql/mssql_driver.php b/system/database/drivers/mssql/mssql_driver.php
index c74f9683b..67557196c 100644
--- a/system/database/drivers/mssql/mssql_driver.php
+++ b/system/database/drivers/mssql/mssql_driver.php
@@ -489,6 +489,29 @@ class CI_DB_mssql_driver extends CI_DB {
// --------------------------------------------------------------------
/**
+ * Insert batch statement
+ *
+ * Generates a platform-specific insert string from the supplied data.
+ *
+ * @param string $table Table name
+ * @param array $keys INSERT keys
+ * @param array $values INSERT values
+ * @return string|bool
+ */
+ protected function _insert_batch($table, $keys, $values)
+ {
+ // Multiple-value inserts are only supported as of SQL Server 2008
+ if (version_compare($this->version(), '10', '>='))
+ {
+ return parent::_insert_batch($table, $keys, $values);
+ }
+
+ return ($this->db->db_debug) ? $this->db->display_error('db_unsuported_feature') : FALSE;
+ }
+
+ // --------------------------------------------------------------------
+
+ /**
* Close DB Connection
*
* @return void