create sequence seq_test star with 1 increment by 1 nocache nomaxvalue; create table xxx(id); create or replace trigger "trixxx" before insert on xxx referencing old as old new as new for each row declare begin select set_test.nextval into :new.id from dual; end trixxx;