摘要:
--方式一:用SEQUENCE实现,插入时使用NEXTVAL获取自增整数的值CREATE TABLE TEMPA2(SID NUMBER NOT NULL,--自增整数列SNAME VARCHAR2(200),CONSTRAINT PK_TEMPA2 PRIMARY KEY(SID) );CREATE SEQUENCE SEQ_TEMPA2 INCREMENT BY 1 START WITH 1 NOMAXVALUE NOCYCLE;--TEMPA2.SIDINSERT INTO TEMPA2(SID,SNAME) VALUES(SEQ_TEMPA2.NEXTVAL,'A1') 阅读全文