插入数据
向部门表里插入数据
insert into Department(DepartmentName,DepartmentRemark)
values('市场部','...')
insert into Department(DepartmentName,DepartmentRemark)
values('软件部','...')
insert into Department(DepartmentName,DepartmentRemark)
values('企划部','...')
--简写 不建议使用,因为数据的列可能会有变化
insert into Department values('企划部','...')
--一次性插入多条数据
insert into Department(DepartmentName,DepartmentRemark)
select '测试部','...' union
select '实施部','....' union
select '产品部','....'
向职级表中插入数据
insert into [Rank](RankName,RankRemark)
select '初级','...' union
select '中级','...' union
select '高级','...'
向员工表中插入数据
insert into People(DepartmentId,RankId,PeopleName,PeopleSex,PeopleBirth,
PeopleSalary,PeoplePhone,PeopleAddr)
values(1,1,'刘备','男','1988-8-1','3000','1783278324','中国')
标签:02,insert,...,into,插入,values,Department,数据,select
From: https://www.cnblogs.com/Starry-blog/p/16797305.html