一、基本建表语句
[code]create table GROUPINFO
(
ID VARCHAR2(32) not null,
GROUP_TYPE VARCHAR2(20),
GROUP_NAME VARCHAR2(255) not null,
MAINTAIN_LEVEL NUMBER,
CUSTOMER_NAME VARCHAR2(20),
CUSTOMER_TEL VARCHAR2(20)
)
tablespace EOMS_DB
pctfree 10
initrans 1
maxtrans 255
storage
(
initial 128K
minextents 1
maxextents unlimited
);
[/code]
二、添加primary key
[code]alter table GROUPINFO
add primary key (ID)
using index
tablespace EOMS_DB
pctfree 10
initrans 2
maxtrans 255
storage
(
initial 64K
minextents 1
maxextents unlimited
);[/code]
[code]create table GROUPINFO
(
ID VARCHAR2(32) not null,
GROUP_TYPE VARCHAR2(20),
GROUP_NAME VARCHAR2(255) not null,
MAINTAIN_LEVEL NUMBER,
CUSTOMER_NAME VARCHAR2(20),
CUSTOMER_TEL VARCHAR2(20)
)
tablespace EOMS_DB
pctfree 10
initrans 1
maxtrans 255
storage
(
initial 128K
minextents 1
maxextents unlimited
);
[/code]
二、添加primary key
[code]alter table GROUPINFO
add primary key (ID)
using index
tablespace EOMS_DB
pctfree 10
initrans 2
maxtrans 255
storage
(
initial 64K
minextents 1
maxextents unlimited
);[/code]