Re: SELECT INTO but append not create new table - How?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Alan T(dot) Miller" <amiller(at)hollywood101(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: SELECT INTO but append not create new table - How?
Date: 2004-01-28 02:28:18
Message-ID: 5513.1075256898@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

"Alan T. Miller" <amiller(at)hollywood101(dot)com> writes:
> I messed around with the 'INSERT INTO' SQL command, but this assumes that
> the table you are 'selecting into' does not exist and you want to create
> that table. My problem is that the table exists and I just want to append
> the information to the archive table.

I think you are looking for INSERT ... SELECT. See the INSERT man page
or any book about SQL.

regards, tom lane

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Alan T. Miller 2004-01-28 02:40:49 Re: SELECT INTO but append not create new table - How?
Previous Message Alan T. Miller 2004-01-28 02:03:15 SELECT INTO but append not create new table - How?