hi...
> My question is:
> "CREATE TABLE t1 (word text)"
> "INSERT INTO t1 VALUES('xxx')" (using SPI_execp)
>
> So, is there any way to obtain OID of word 'xxx' just after insertion
> without doing "SELECT oid FROM t1 WHERE word='xxx'"?
i've been watching this thread and it has caused this thought rumble forth:
would it be possible to add a RETURN clause to INSERT? e.g.
INSERT into t1 VALUES('xxx') RETURN oid;
i could see where this would be useful in many different circumstances.. i
know this isn't standards compliant, but would be very cool =) i know that with
triggers, you have access to the current/old/new information, could this be
harnessed to supply a RETURN facility?
just a thought.. probably ignorable.
--
Aaron J. Seigo
Sys Admin