You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

CategoryLog.sql 546B

1234567891011121314
  1. CREATE TABLE [dbo].[CategoryLog] (
  2. [CategoryLogID] INT IDENTITY (1, 1) NOT NULL,
  3. [CategoryID] INT NOT NULL,
  4. [LogID] INT NOT NULL,
  5. CONSTRAINT [PK_CategoryLog] PRIMARY KEY CLUSTERED ([CategoryLogID] ASC),
  6. CONSTRAINT [FK_CategoryLog_Category] FOREIGN KEY ([CategoryID]) REFERENCES [dbo].[Category] ([CategoryID]),
  7. CONSTRAINT [FK_CategoryLog_Log] FOREIGN KEY ([LogID]) REFERENCES [dbo].[Log] ([LogID])
  8. );
  9. GO
  10. CREATE NONCLUSTERED INDEX [ixCategoryLog]
  11. ON [dbo].[CategoryLog]([LogID] ASC, [CategoryID] ASC);