Re: How can I make multiple insertions ? - Mailing list pgsql-novice

From Andreas Kretschmer
Subject Re: How can I make multiple insertions ?
Date
Msg-id 20060311131716.GA23667@KanotixBox
Whole thread Raw
In response to How can I make multiple insertions ?  (Miguel <migabolinux@yahoo.com>)
List pgsql-novice
Miguel <migabolinux@yahoo.com> schrieb:

> I have read that the only solution for insertions
> multiple in Postgres is using copy , please could
> somebody explains to me if exist another posibility .

Yes, of course ;-)

test=# create table foobar (x int, y int);
CREATE TABLE
test=# insert into foobar select 1,1 union select 2,2 union select 3,3;
INSERT 0 3
test=# select * from foobar ;
 x | y
---+---
 1 | 1
 2 | 2
 3 | 3
(3 rows)


HTH, Andreas
--
Really, I'm not out to destroy Microsoft. That will just be a completely
unintentional side effect.                              (Linus Torvalds)
"If I was god, I would recompile penguin with --enable-fly."    (unknow)
Kaufbach, Saxony, Germany, Europe.              N 51.05082°, E 13.56889°

pgsql-novice by date:

Previous
From: Miguel
Date:
Subject: How can I make multiple insertions ?
Next
From: "Ronni"
Date:
Subject: Permissions to users ??? (FATAL: Ident authentication failed for user)