Consider the MyTable table structure. I frequently want to either insert a new record if one doesn't already exist or edit an existing record.
Essentially:
IF (key exists)
run update command
ELSE
run insert command
What would be the most effective way to write this?