Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Insert values in tables with Matched colums from another table

1003106Jul 4 2013 — edited Jul 4 2013

Hi Guys,

I have two tables with three columns. I am using oracle 11g, version 11.2.0.1

SQL> create table t1 (id number,name varchar2(200),age number);

Table created.

SQL> create table t2 (id number,name varchar2(200),salary number);

Table created.

Table t1 is having some values but Table t2 is empty.

I want to insert values in t2 from matched coulmns from t1 i.e id and name coulumn is common amongst two tables. I want id and name value should insert in t2.

There are lot of coulms in both the tables, here for just example I have taken three coulmsn. I want to write a query where I want to insert columns in T2 which are matched with Table T1.

Please help me..

Regards,

Arijit

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 1 2013
Added on Jul 4 2013
8 comments
2,163 views