StrataFrame Forum

Unique Index Problem

http://forum.strataframe.net/Topic14682.aspx

By fansanitis - 3/6/2008

I have a number of unique indexes on my database.  When I import it into a DDT project, all the indexes imported as non-unique.  So I changed them all in DDT to be unique and then deployed the database.  Everything worked fine except 1 index got deployed as non-unique.  So I checked the DDT project and it IS marked as unique.  So I unchecked and checked Unique just to make sure.  I redeployed the database and the progress log said the index in question was successfully altered.  So I went into the SQL Server Management Studio and the index is still non-unique.  Checked the DDT project again and the index is flagged as UNIQUE.  Any idea why this index won't deploy as unique?

Thanks!!

By Trent L. Taylor - 3/6/2008

This type of thing is hard to diagnose over a post.  If you deploy to a fresh instance (i.e. create a new database or deploy to another SQL Server) and the index is created properly, then there is probably some pre-existing issue that the SMO is having an issue with.  The first thing that I would do is manually delete the index on the server, deploy, and if it is created correctly from that point forward then you are probably good to go.  Past that I don't have any "abundantly wise advice" without actually getting into the very specifics and details in a reproducable state.