If you want to insert all columns, then
insert into def select * from abc;
here the number of columns in def should be equal to abc.
if you want to insert subsets of columns then
insert into def (col1,col2, col3 ) select scol1,scol2,scol3 from abc;
if you want to insert some hardcorded values ββthen
insert into def (col1, col2,col3) select 'hardcoded value',scol2, scol3 from abc;
kanishka vatsa Sep 08 '16 at 6:57 2016-09-08 06:57
source share