1

My problem is, i have two table namely enq_tab and feed_back_tab. i need to insert some columns from enq_tab into feed_back_tab and some columns are from a webpage ie, a jsp...

ex: enq_tab: enq_id,name,email,mobile,address,enq_date are columns; feed_back_tab:enq_id,name,email,mobile,address,enq_date,feed_back,comments,suggestions are columns

here i will get the feed_back,comments, suggestions from the JSP , and remaining columns from the enq_tab based on enq_id, which already present in database.

anybody help me with some suggestions..

Thank in advance..

Bhadra
  • 1,131
  • 4
  • 11
  • 14

1 Answers1

7

I think you can do this way.

insert into table1(COL1,COL2,COL3,COL4)
select col1,col2,jspvaribalevalue1,jspvariblevalue2 from table2
Balaswamy Vaddeman
  • 8,360
  • 3
  • 30
  • 40