CREATE TABLE [dbo].[DocumentGroup]
(
[DocumentGroupID] [int] NOT NULL IDENTITY(1, 1),
[Description] [varchar] (64) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[SortBy] [int] NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[DocumentGroup] ADD CONSTRAINT [PK_DocumentGroup] PRIMARY KEY CLUSTERED ([DocumentGroupID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
ALTER TABLE [dbo].[DocumentGroup] ADD CONSTRAINT [IX_DocumentGroup_Description] UNIQUE NONCLUSTERED ([Description]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
GRANT SELECT ON [dbo].[DocumentGroup] TO [MssExec]
GRANT INSERT ON [dbo].[DocumentGroup] TO [MssExec]
GRANT DELETE ON [dbo].[DocumentGroup] TO [MssExec]
GRANT UPDATE ON [dbo].[DocumentGroup] TO [MssExec]
GO
EXEC sp_addextendedproperty N'MS_Description', N'The description of the document group.', 'SCHEMA', N'dbo', 'TABLE', N'DocumentGroup', 'COLUMN', N'Description'
GO
EXEC sp_addextendedproperty N'MS_Description', N'The primary key.', 'SCHEMA', N'dbo', 'TABLE', N'DocumentGroup', 'COLUMN', N'DocumentGroupID'
GO