创建触发器在表中播入数据时ID自动增长
create table ttt (id number primary key ,name varchar2(20),age number(2)) create or replace trigger gger_tt before insert on ttt for each row when (new.id is null) begin select ttt_sequence.nextval into :new.id from dual; end;
create table ttt (id number primary key ,name varchar2(20),age number(2)) create or replace trigger gger_tt before insert on ttt for each row when (new.id is null) begin select ttt_sequence.nextval into :new.id from dual; end;