create or replace trigger cux.cux_rebate_line_trg
before insert on cux.cux_rebate_line for each row
declare
l_id number;
begin
select cux_rebate_line_s.nextval into :new.line_id from dual;
exception
when others then
raise_application_error(- 20100,
‘get_sequence_nextval error‘ || sqlerrm );
end;
原文:http://blog.csdn.net/gh320/article/details/18240839