unfortunately , with IDS is not possible to execute any command differ of INSERT,DELETE,UPDATE,EXECUTE PROC/FUNC inside a Trigger.
You need create a SPL to get the nextval .
Code:
CREATE SEQUENCE Y;
create procedure sp_smou_auto() returning integer
return y.nextval ;
end procedure
;
CREATE TRIGGER smou_auto INSERT on smou
referencing new as n
for each row
when (n.id is null) (
execute procedure sp_smou_auto() into id
)
;