From 5289f27c07bfb1d961317de351c4819f25dd5f2e Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Mon, 3 Nov 2014 22:45:28 +0200 Subject: Polish changes following #3305 Also add support for field comments in PostgreSQL & Oracle ... only via alter_table() for now :/ --- system/database/drivers/mysql/mysql_forge.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'system/database/drivers/mysql/mysql_forge.php') diff --git a/system/database/drivers/mysql/mysql_forge.php b/system/database/drivers/mysql/mysql_forge.php index 282e2d1d8..1088c0321 100644 --- a/system/database/drivers/mysql/mysql_forge.php +++ b/system/database/drivers/mysql/mysql_forge.php @@ -88,7 +88,7 @@ class CI_DB_mysql_forge extends CI_DB_forge { * * @var string */ - protected $_null = 'NULL'; + protected $_null = 'NULL'; // -------------------------------------------------------------------- @@ -185,7 +185,6 @@ class CI_DB_mysql_forge extends CI_DB_forge { $extra_clause = ' FIRST'; } - $comment_clause = isset($field['comment']) ? ' COMMENT ' . $field['comment'] : ''; return $this->db->escape_identifiers($field['name']) .(empty($field['new_name']) ? '' : ' '.$this->db->escape_identifiers($field['new_name'])) @@ -195,7 +194,7 @@ class CI_DB_mysql_forge extends CI_DB_forge { .$field['default'] .$field['auto_increment'] .$field['unique'] - .$comment_clause + .(empty($field['comment']) ? '' : ' COMMENT '.$field['comment']) .$extra_clause; } -- cgit v1.2.3-24-g4f1b