From: | "Rod Taylor" <rbt(at)zort(dot)ca> |
---|---|
To: | "Neil Conway" <nconway(at)klamath(dot)dyndns(dot)org>, "PostgreSQL Hackers" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: insert with multiple targetLists |
Date: | 2002-05-01 23:51:46 |
Message-ID: | 221201c1f16b$275a0450$ad02000a@jester |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
> INSERT INTO t1 (c1) VALUES (1), (2);
>
> would be executed in a similar fashion to:
>
> INSERT INTO t1 (c1) VALUES (1);
> INSERT INTO t1 (c1) VALUES (2);
>
> Does this sound reasonable?
I debated doing the above too. In fact, I had a partial
implementation at one point.
However, the resulting purpose of allowing such a construct is to
enable the speeds copy achieves with the variation that is found in an
insert. So, the above transformation method really doesn't accomplish
much except a new style for many inserts. But it is quite a bit
easier simply to code each insert individually if there is a minimal
speed gain. Large strings may reach query length limits in other
systems using this style (look at a MySQL dump sometime). You're
really only good for about 50 or 60 records in a single insert
statement there.
I'd tend to run it like a copy that can resolving expressions and
defaults.
From | Date | Subject | |
---|---|---|---|
Next Message | David Terrell | 2002-05-01 23:59:34 | Re: PostgreSQL mission statement? |
Previous Message | cbbrowne | 2002-05-01 23:25:12 | Re: PostgreSQL mission statement? |