"Andrew Hammond" <[EMAIL PROTECTED]> writes:
> Rules:
> t2_part AS
> ON INSERT TO t2
>WHERE new.id > 10 DO INSTEAD INSERT INTO t2_child (id, name)
> VALUES (new.id, new.name)
"new.id" is replaced by "nextval('t2_id_seq'::regclass)" each time it
appears ... which will be four separat
Perhaps I'm missing something here, but it looks like I'm getting an
insert into both the parent and child tables when my RULE's where
clause is based on a DEFAULT generated from a sequence. It looks like
nextval on the sequence is called 3 times for every insert.
I don't know if this is properly