How to insert records into the table by subquery

Posted by Goldytech under Sql Server category on | Views : 2389
Suppose you have tableA with n number of fields if you wish to enter bulk records from some other tableB which has same fields then use this code

INSERT INTO TABLEA (col1,col2,col3)
(SELECT col1,col2,col3 FROM TABLEB)

Comments or Responses

Login to post response