I am trying to exicute this query in sql server management studio. I don't understand why i am getting an error.Thanks for any help! :)create table #test( col1 varchar(6) not null, col2 numeric(5,2) not null, col3 varchar(5) not null, col4 numeric(4,0) not null)MERGE into table1 ausing #test b on a.col1 = b.col1when matched thenupdatesetcol4 = -1when not matched theninsert col1, col2, col3, col4values b.col1, b.col2, b.col3, b.col4
The error is:Msg 156, Level 15, State 1, Line 8Incorrect syntax near the keyword 'into'.
thanks in advance!