How to rename mysql column from help
to content
in my table tbl_help
mysql_query("ALTER TABLE tbl_help " . "CHANGE COLUMN help content;");
How to rename mysql column from help
to content
in my table tbl_help
mysql_query("ALTER TABLE tbl_help " . "CHANGE COLUMN help content;");
From mySql Doc pages:
You can rename a column using a CHANGE old_col_name new_col_name column_definition
clause.
You've got to include the definition of the table in the change column statement (not sure why, but that's what the documentation says.)
So this should work:
mysql_query("ALTER TABLE tbl_help " . "CHANGE COLUMN help content VARCHAR(200) ;");