diff options
author | admin <devnull@localhost> | 2006-09-03 20:29:51 +0200 |
---|---|---|
committer | admin <devnull@localhost> | 2006-09-03 20:29:51 +0200 |
commit | 5e7ac0e9a4319d29fd23b5525aef05ad28ff0706 (patch) | |
tree | b198ff40f058e628032f0108ee2dff180d4871e5 /system/drivers/DB_postgre.php | |
parent | 1cf89aab5fff8c8068cbf0ed18038b6e4fd4f605 (diff) |
Diffstat (limited to 'system/drivers/DB_postgre.php')
-rw-r--r-- | system/drivers/DB_postgre.php | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/system/drivers/DB_postgre.php b/system/drivers/DB_postgre.php index 673dea335..f0be3c0b1 100644 --- a/system/drivers/DB_postgre.php +++ b/system/drivers/DB_postgre.php @@ -174,7 +174,7 @@ class CI_DB_postgre extends CI_DB { if ($table == '') return '0'; - $query = $this->query("SELECT COUNT(*) AS numrows FROM ".$this->dbprefix.$table.""); + $query = $this->query('SELECT COUNT(*) AS numrows FROM "'.$this->dbprefix.$table.'"'); if ($query->num_rows() == 0) return '0'; @@ -216,7 +216,6 @@ class CI_DB_postgre extends CI_DB { * * This function adds backticks if the table name has a period * in it. Some DBs will get cranky unless periods are escaped. - * NOT NEEDED FOR POSTGRE * * @access public * @param string the table name @@ -224,12 +223,10 @@ class CI_DB_postgre extends CI_DB { */ function escape_table($table) { - /* if (stristr($table, '.')) { - $table = preg_replace("/\./", "`.`", $table); + $table = '"'.preg_replace("/\./", '"."', $table).'"'; } - */ return $table; } |