Permalink
Browse files

ability to move field after another when modifying it

  • Loading branch information...
1 parent fc514ca commit f955c15d46c1ac73812de3123ca6e91d384809ca @mlazarov mlazarov committed Jan 13, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 system/database/DB_forge.php
@@ -294,7 +294,7 @@ public function drop_column($table = '', $column_name = '')
* @param string the column definition
* @return bool
*/
- public function modify_column($table = '', $field = array())
+ public function modify_column($table = '', $field = array(), $after_field = '')
{
if ($table == '')
{
@@ -317,7 +317,7 @@ public function modify_column($table = '', $field = array())
show_error('Field information is required.');
}
- $sql = $this->_alter_table('CHANGE', $this->db->dbprefix.$table, $this->fields);
+ $sql = $this->_alter_table('CHANGE', $this->db->dbprefix.$table, $this->fields, $after_field);
$this->_reset();
if ($this->db->query($sql) === FALSE)

0 comments on commit f955c15

Please sign in to comment.