Enable is not available in coverage index in SQL Server 2008 Express

In MS SQL Server Manager Studio 2008 Express, the Included Columns field is always grayed out in the Indexes / Keys window in the database diagram design.

For reference, this should be available until I create a clustered index.

Also, if I run a query to create an index (which works fine), the created query does not display the table in which it was added.

I do not see anywhere where MS says that this feature is not available in the Express version.

Any ideas?

Additional data:

This is the script that creates the table:

CREATE UNIQUE INDEX IX_SocialTypes_Cover ON ClientSocialTypes(ClientID, SocialTypeID, [Source]) INCLUDE (URLID) 

Here is the gen script table (no index):

 CREATE TABLE [dbo].[ClientSocialTypes]( [SocialTypeID] [int] IDENTITY(1,1) NOT NULL, [ClientID] [int] NOT NULL, [SocialTypeClassID] [tinyint] NOT NULL, [Source] [nvarchar](50) NOT NULL, [TagCount] [int] NOT NULL, [URLID] [int] NULL, CONSTRAINT [PK_ClientSources] PRIMARY KEY CLUSTERED ( [SocialTypeID] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] ) ON [PRIMARY] GO ALTER TABLE [dbo].[ClientSocialTypes] WITH CHECK ADD CONSTRAINT [FK_ClientSocialTypes_Clients] FOREIGN KEY([ClientID]) REFERENCES [dbo].[Clients] ([ClientID]) ON UPDATE CASCADE ON DELETE CASCADE GO ALTER TABLE [dbo].[ClientSocialTypes] CHECK CONSTRAINT [FK_ClientSocialTypes_Clients] GO ALTER TABLE [dbo].[ClientSocialTypes] WITH CHECK ADD CONSTRAINT [FK_ClientSocialTypes_SocialTypeClasses] FOREIGN KEY([SocialTypeClassID]) REFERENCES [dbo].[SocialTypeClasses] ([SocialTypeClassID]) GO ALTER TABLE [dbo].[ClientSocialTypes] CHECK CONSTRAINT [FK_ClientSocialTypes_SocialTypeClasses] GO ALTER TABLE [dbo].[ClientSocialTypes] ADD CONSTRAINT [DF_ClientSocialTypes_SocialTypeClassID] DEFAULT ((1)) FOR [SocialTypeClassID] GO ALTER TABLE [dbo].[ClientSocialTypes] ADD CONSTRAINT [DF_ClientSocialTypes_TagCount] DEFAULT ((0)) FOR [TagCount] GO ALTER TABLE [dbo].[ClientSocialTypes] ADD CONSTRAINT [DF_ClientSocialTypes_HasTrackedURL] DEFAULT ((0)) FOR [URLID] GO 
+4
source share
3 answers

It turns out that in the full version of SQL Server this is also grayed out. In SSMS, use the object explorer (not the constructor) to go to {database_name}> Tables> {table_name}> Indexes to manage the indexes that include.

+5
source

There are TWO different index dialogs. Ancient terrible terrible and new (just opened it), which actually allows you to change these things.

OLD HORRIBLE ONE

  • Right-click on a table in the list of main tables.
  • Click "Design"
  • Right-click on the column list and select "Indexes / Keys"

This does not allow you to modify the included columns.

NEW NICE ONE

  • Expand the table in the list of main tables to display the Columns, Keys, Constraints, Triggers, etc. folders.
  • Expand the Indexes folder
  • Right-click Indexes New Index folder
  • Right-click an existing index and click Properties to edit an existing index.

This newer dialog allows you to do a lot more, and I'm a little disappointed at Microsoft to keep the old one and how long it made me discover it.

+7
source

An index can actually be a unique constraint (using CREATE / ALTER TABLE), rather than an index created using CREATE INDEX. Unique restrictions do not allow INCLUDE.

This is pretty confusing ... generate a script to write / index / key table and you can confirm.

Edit:

  • When you create the index separately, you need to update the Object Explorer

  • Do you have 2 SocialType tables in different schemas? (for example, dbo.SocialType and [domain\myuser].SocialType ). This can happen if you do not specify a schema in DDL operations.

+1
source

All Articles