Unique Column on SharePoint 2007 Document Library
Hi, how do i make about 3 columns unique on sharepoint 2007 document library. Thanks
June 3rd, 2010 10:15am

You can't do that out of the box with any sharepoint 2007 products (WSS or MOSS). The "standard" technique is to write an event handler that rejects the change if it finds a duplicate value. If you're handy with coding in sharepoint, there's a good msdn article on this topic which I can dig up. You could probabliy also do this with jQuery (again, coding). The jQuery code would invoke a web sevice that tries to find a row that has the duplicate value and then rejects the change. The advantage to this approach is that it wouldn't require server side coding, but it's still a code-heavy approach. --Paul Galvin, Computer Generated Solutions (CGS) Microsoft MVP - SharePoint Blogging @ http://feeds.feedburner.com/PaulGalvinsSharePointSpace Twitter @ http://www.twitter.com/pagalvin
Free Windows Admin Tool Kit Click here and download it now
June 3rd, 2010 1:35pm

Hi, There is a feature available in codeplex for this purpose: Unique Column Policy This Feature creates a new Information Policy that allows you to specify a column in a list or library that should have unique values. It is accessible from the Information Policy link on the list/library settings page. When you turn on the policy, you can then select the column where the unique constraint should be applied.
June 3rd, 2010 2:03pm

Thanks i know that i cannot achieve this out of the box.I have downloaded the unique column policy feature. but the limitation is that u can only apply it to 1 column @ a time. It is not flexible. Pls, provide link for the sample event handler code. thanks
Free Windows Admin Tool Kit Click here and download it now
June 3rd, 2010 10:48pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics