学生选课数据库SQL语句练习题——教师表

表(四)Teacher(教师表)

属性名

数据类型

可否为空

含   义

Tno

Varchar2(3)

教工编号(主键)

Tname

Varchar2(4)

教工姓名

Tsex

Varchar2(2)

教工性别

Tbirthday

Date

教工出生年月

Prof

Varchar2(6)

职称

Depart

Varchar(10)

教工所在部门

-- Create table
create table TEACHER
(
  tno       VARCHAR2(3) not null,
  tname     VARCHAR2(4) not null,
  tsex      VARCHAR2(2) not null,
  tbirthday DATE,
  prof      VARCHAR2(6),
  depart    VARCHAR2(10)
)
tablespace TEST
  pctfree 10
  initrans 1
  maxtrans 255;
-- Add comments to the table 
comment on table TEACHER
  is '教师表';
-- Add comments to the columns 
comment on column TEACHER.tno
  is '教工编号(主键)';
comment on column TEACHER.tname
  is '教工姓名';
comment on column TEACHER.tsex
  is '教工性别';
comment on column TEACHER.tbirthday
  is '教工出生年月';
comment on column TEACHER.prof
  is '职称';
comment on column TEACHER.depart
  is '教工所在部门';

 

原文地址:https://www.cnblogs.com/jakeasd/p/5567375.html