Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: Insert from a table to another

Re: Insert from a table to another

From: james ellis <jellis24_gso_at_yahoo.com>
Date: Fri, 27 Apr 2001 10:14:28 -0700
Message-ID: <F001.002F43D6.20010427081112@fatcity.com>

You can do a simple insert/select statement within pl/sql

declare
begin
insert into table_a
  (select * from table_b);
end;
/

if all the columns are in the same order in both tables. If not list the columns out.

James
--- Roland.Skoldblom_at_ica.se wrote:
> Any one whom can give me a good advice, on a pl/sql
> procedure, that delete data from table a, then runs
> a query from table b and and that insert this query
> into table a.
> Pleas help me with a good example.
> Thanks
>
> Roland Sköldblom
>
>
>
>
> --
> Please see the official ORACLE-L FAQ:
> http://www.orafaq.com
> --
> Author:
> INET: Roland.Skoldblom_at_ica.se
>
> Fat City Network Services -- (858) 538-5051 FAX:
> (858) 538-5051
> San Diego, California -- Public Internet
> access / Mailing Lists
>



> To REMOVE yourself from this mailing list, send an
> E-Mail message
> to: ListGuru_at_fatcity.com (note EXACT spelling of
> 'ListGuru') and in
> the message BODY, include a line containing: UNSUB
> ORACLE-L
> (or the name of mailing list you want to be removed
> from). You may
> also send the HELP command for other information
> (like subscribing).


Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices http://auctions.yahoo.com/
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: james ellis
  INET: jellis24_gso_at_yahoo.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Fri Apr 27 2001 - 12:14:28 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US