📄 无标题1.sql
字号:
CREATE DATABASE Teacherbase
ON
( NAME = Teacherbase_dat,
FILENAME = 'c:\program files\microsoft sql server\mssql\data\Teacherbasedat.mdf',
SIZE = 10,
MAXSIZE = 50,
FILEGROWTH = 5 )
LOG ON
( NAME = 'Teacherbase_log',
FILENAME = 'c:\program files\microsoft sql server\mssql\data\Teacherbaselog.ldf',
SIZE = 5MB,
MAXSIZE = 25MB,
FILEGROWTH = 5MB )
use Teacherbase
create table tinfo
(
no bigint not null,
name nvarchar(20) not null,
sex nvarchar(2) not null,
dept nvarchar (30) not null,
age int not null,
worktime int not null,
pro nvarchar(20) not null,
cla nvarchar(20) not null,
expe nvarchar(20) not null,
primary key (no)
);
use Teacherbase
create table twage(
no bigint not null,
name nvarchar(20) not null,
wage float not null,
othwage float not null,
monwage float not null,
primary key (no)
);
use database Teacherdatabase
insert into tinfo values (1,'LiHua','男','计算机系',34,1986,'教师','讲师','毕业于南大')
insert into tinfo values (2,'LiMing','男','软件学院',45,1965,'系主任','教授','在上海交大读研')
insert into tinfo values (3,'Jeary','女','外国语院',30,1990,'博导','教授','在同济深造')
insert into tinfo values (4,'WangHong','女','经管院',35,1988,'辅导员','研究生','在上海交大读研')
insert into twage values (1,'LiHua',3000,5000,700)
insert into twage values (2,'LiMing',37809,4000,4799)
insert into twage values (3,'Jeary',7855,786,2700)
insert into twage values (4,'WangHong',6755,4543,677)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -