Home > Database > Mysql Tutorial > mysql删除字段语句_MySQL

mysql删除字段语句_MySQL

WBOY
Release: 2016-06-01 13:13:25
Original
2634 people have browsed it

#删除字段
ALTER TABLE evan DROP COLUMN age

#添加字段
ALTER TABLE evan ADD COLUMN age2 VARCHAR(20) COMMENT '年龄'

#修改字段注释
ALTER TABLE evan MODIFY COLUMN age2 VARCHAR(20) COMMENT '年龄2'

#修改字段名字
ALTER TABLE evan CHANGE COLUMN age2 age VARCHAR(4)

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template