I was doing some experimenting and was wondering why the following does
not work:
CREATE TABLE accounts (
id SERIAL PRIMARY KEY NOT NULL,
accounts_id INTEGER REFERENCES accounts,
name TEXT
);
INSERT INTO accounts (accounts_id, name) VALUES (
(INSERT INTO accounts (accounts_id, name) VALUE
On Mon, 2010-04-05 at 09:10 +0200, Andreas Kretschmer wrote:
> Cliff Wells wrote:
>
> > As far as I can see, INSERT INTO...RETURNING is semantically equivalent
> > to SELECT...FROM with a side-effect, so it seems this construct should
> > work. Can someone shed some light?
>
> Well, at the mome
Cliff Wells wrote:
> As far as I can see, INSERT INTO...RETURNING is semantically equivalent
> to SELECT...FROM with a side-effect, so it seems this construct should
> work. Can someone shed some light?
Well, at the moment you can't reuse the RETURNING-values, you have to
wait for 9.1, writeabl
I was doing some experimenting and was wondering why the following does
not work:
CREATE TABLE accounts (
id SERIAL PRIMARY KEY NOT NULL,
accounts_id INTEGER REFERENCES accounts,
name TEXT
);
INSERT INTO accounts (accounts_id, name) VALUES (
(INSERT INTO accounts (accounts_id, name) VALUE