Column
Data Type
Comments
CLASSNo
Positive whole number
Primary key
CLASSame Variable length string
Maximum length of 20 characters; nulls not allowed
CLASSParentNo
Positive whole number
Refers to CLASSNo; nulls allowed for the case of a parent CLASS
create table t(
classno number primary key check(classno>0),
classame varchar(20) not null,
classparentno number referrences by tbl_name(classno))
至于classparentno的positive直接在父表中定义即可