I want to know what is MERGE statement in SQL Server.
Thank you.
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Jignesh TrivediPosted Jul 24, 2012, 5:25 AM
Hi,
Merge enable us to performs insert, update, or delete operations on a target table based on the results of a join with a source table. In other word it provides an efficient way to perform multiple DML operations base on condition.
please refer
http://technet.microsoft.com/en-us/library/bb510625.aspx
http://www.mssqltips.com/sqlservertip/1704/using-merge-in-sql-server-to-insert-update-and-delete-at-the-same-time/
hope this will help you.
Vikrant MorePosted Jul 24, 2012, 4:16 AM
here is the article i found which helps you to know what is MERGE Statement in SQL Server.
http://blog.sqlauthority.com/2008/08/28/sql-server-2008-introduction-to-merge-statement-one-statement-for-insert-update-delete/
Rahul BhattPosted Jul 19, 2012, 7:22 AM
make your query as following way
select CAST(FieldName1 as varchar)+' - ' + CAST(FieldName2 as varchar) from TableName
Satyapriya NayakPosted Jul 19, 2012, 7:13 AM