Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

With Sharepoint 2010, non duplicates can be enforced at the site column / list definition level (a unique index).

Is there a built in way to do instead of failing with "duplicates not allowed", during an insert. Is it possible to instead replace that list item.

I can manually do this with a bit of custom code, but I'm wondering if there is a build in way to do this using the object model / caml?

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

No, you have to implement this on your own. That is check if the unique value exists and then either add or update.

share|improve this answer
    
Thought as much, just making sure :) Thanks! –  user879 Feb 2 '11 at 11:38
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.