I installed a few new themes a few weeks ago and everything went off without a hitch. Yesterday, I go to my site and attempt to change the theme and get this error:

Failed to enable constraints. One or more rows contain values violating non-null, unique, or foreign-key constraints.

Any ideas what would cause this? I only get it on the themeweb.aspx page. The only recent changes I made was installing those new themes…

I'm on WSS 2007.

Thanks for any help.

1 Answer 1


You'll need to look in the file

 C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\LAYOUTS\1033\SPTHEMES.XML 

for any duplicate template ids and remove the dups.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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