Quantcast
Channel: SQL Server Database Engine forum
Viewing all articles
Browse latest Browse all 15264

Question about Insert and Update

$
0
0

Hi All,

   I have a table which gets its data from another table. The destination table has 2 columns and it has index on it, which doesn't allow duplicates. So my question is I want to create a program in SQL Server 2008 R2 itself which checks for duplicates and if the duplicate is not there then it inserts, if not it just updates, so is there a way to do this?

Thanks for any tips or help

Asha

 


Viewing all articles
Browse latest Browse all 15264

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>