Re: select into... - Mailing list pgsql-admin

From Fernando Arancibia
Subject Re: select into...
Date
Msg-id 9c7ce58a0903161613m1bf644a2te4efc5a5680abb76@mail.gmail.com
Whole thread Raw
In response to select into...  ("Tena Sakai" <tsakai@gallo.ucsf.edu>)
List pgsql-admin
Hi, try

insert into my_table select * from old_table where (some_condition);

bye 
Fernando.

2009/3/16 Tena Sakai <tsakai@gallo.ucsf.edu>

Hi Everybody,

I want to execute a query below:

  select *
    into my_table
    from old_table
   where (some_condition);

The trouble is that the manual page states that this would
"SELECT INTO creates a new table and fills it with data
computed by a query."

What I want is to append my_table.  Is there any way to
get postgres to do what I want done?

Thank you in advance.

Regards,

Tena Sakai
tsakai@gallo.ucsf.edu


pgsql-admin by date:

Previous
From: "Tena Sakai"
Date:
Subject: Re: select into...
Next
From: "Lori, Giancarlo"
Date:
Subject: Need help to restore database