Home > Database > Mysql Tutorial > mysql初学者必学语句整理_MySQL

mysql初学者必学语句整理_MySQL

WBOY
Release: 2016-06-01 13:45:52
Original
975 people have browsed it

bitsCN.com

MySQL 添加列,修改列,删除列ALTER TABLE:添加,修改,删除表的列,约束等表的定义。

查看列:desc 表名; 
修改表名:alter table   old _name  rename to new_name; 
添加列:alter table 表名add column 列名varchar(100); 
删除列:alter table 表名drop column 列名; 
修改列名:alter table 表名change old_name  new_name  字符类型; 
修改列属性:alter table 表名modify 列名varchar(10);

本文出自 “java技术社区” 博客

bitsCN.com
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