create sequence seq_字段名_表名
minvalue 1
maxvalue 999999999999999999999999999
start with 1
increment by 1
cache 10; CREATE OR REPLACE TRIGGER tri_字段名_表名
BEFORE insert ON 表名
FOR EACH ROW
begin
select seq_字段名_表名.Nextval into:New.自增字段名 from dual;
end;
2023-08-25 21:43:28
create sequence seq_字段名_表名
minvalue 1
maxvalue 999999999999999999999999999
start with 1
increment by 1
cache 10; CREATE OR REPLACE TRIGGER tri_字段名_表名
BEFORE insert ON 表名
FOR EACH ROW
begin
select seq_字段名_表名.Nextval into:New.自增字段名 from dual;
end;