Sequence... [message #375158] |
Wed, 01 August 2001 09:30 |
Otávio
Messages: 6 Registered: April 2001
|
Junior Member |
|
|
Hello there,
How Can I define the default value of field of a table like sequence.nextval?
Do I need set the value by a Trigger (Before Insert)??
Thanx.
|
|
|
Re: Sequence... [message #375178 is a reply to message #375158] |
Thu, 02 August 2001 14:15 |
Todd Barry
Messages: 4819 Registered: August 2001
|
Senior Member |
|
|
Yes, you will need a before row insert trigger to do this
if :new.pk_column is null then
select seq_name.nextval into :new.pk_column;
end if;
|
|
|
|