Solved

Constraint Not Showing Under "Constraints" in Management Studio

Posted on 2006-11-02
4
705 Views
Last Modified: 2013-12-03
I created a new table like this:

IF OBJECT_ID('MyTables') IS NULL
CREATE TABLE MyTables (
id INT IDENTITY (1,1),
SomeName VARCHAR(20) NOT NULL CONSTRAINT UniqueSomeName UNIQUE (SomeName)
);

Now, when I got to Management Studio (2005), the constraint does not show under the "Constraints", but it does show under the "Indexes" and "Statistics". Am I doing something wrong?
0
Comment
Question by:GivenRandy
  • 2
4 Comments
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 500 total points
ID: 17859057
a UNIQUE constraint is implemented by a UNIQUE INDEX. hence it shows up there...
0
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 17859059
>Am I doing something wrong?
no
0
 
LVL 75

Expert Comment

by:Aneesh Retnakaran
ID: 17859079
Check for that one in indexes
0
 
LVL 9

Author Comment

by:GivenRandy
ID: 17859399
LMAO -- Of course. Thanks!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Having an SQL database can be a big investment for a small company. Hardware, setup and of course, the price of software all add up to a big bill that some companies may not be able to absorb.  Luckily, there is a free version SQL Express, but does …
I have a large data set and a SSIS package. How can I load this file in multi threading?
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

947 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now