数据库添表
添加表:
create database test
删除表:
drop database test
使用test:
use test
创建表格:
create table stu :
(
id int primary key'
sex bit'
age int'
name nvarchar(50) not null'
birthday datetime not null'
class int
)
删除表格:
drop table stu
添加 score
alter table stu add score decimal(5'1)
删除列age
alter table stu drop column age
增加值
insert into stu values (1,'true','张三','1995-3-2',1,90.5)
显示和删除
select *from stu
delete from stu
truncate table stu
update stu set name ='李四'