summaryrefslogtreecommitdiffstats
path: root/application/controllers/tools.php
diff options
context:
space:
mode:
Diffstat (limited to 'application/controllers/tools.php')
-rw-r--r--application/controllers/tools.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/application/controllers/tools.php b/application/controllers/tools.php
index f0d8ce6f9..664a9e324 100644
--- a/application/controllers/tools.php
+++ b/application/controllers/tools.php
@@ -59,9 +59,14 @@ class Tools extends MY_Controller {
return;
}
- $this->db->query('SET FOREIGN_KEY_CHECKS = 0');
+
+ if ($this->db->dbdriver !== 'postgre') {
+ $this->db->query('SET FOREIGN_KEY_CHECKS = 0');
+ }
$this->db->query('DROP TABLE '.implode(", ", $tables_to_drop));
- $this->db->query('SET FOREIGN_KEY_CHECKS = 1');
+ if ($this->db->dbdriver !== 'postgre') {
+ $this->db->query('SET FOREIGN_KEY_CHECKS = 1');
+ }
}
function test()