create or replace TRIGGER st_semainiers BEFORE INSERT ON semainiers FOR EACH ROW BEGIN SELECT s_semainiers.nextval INTO :new.p_id FROM dual; END;