Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Update if exist and insert if it doesn't
Message
From
11/08/2001 19:04:45
 
 
To
11/08/2001 16:20:07
General information
Forum:
Microsoft SQL Server
Category:
SQL syntax
Miscellaneous
Thread ID:
00542663
Message ID:
00542694
Views:
13
You can't do it in one instruction. Here's my perfered method:

if exists (select * from mytable where keyfield=keyvalue)
update ...
else
insert

-Mike
Michael Levy
MCSD, MCDBA
ma_levy@hotmail.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform