创建序列
CREATE SEQUENCE API_ATTENDANCE _sequence
MAXVALUE 9999999999999
MINVALUE 1
START WITH 1
INCREMENT BY 1
CACHE 20;
创建触发器
create trigger API_ATTENDANCE _trig before
insert on API_ATTENDANCE for each row
begin
select API_ATTENDANCE _sequence .nextval into:new.id from dual;
//select 序列.nextval into: new.id
end;