USE [BAZA_REKLAM]
GO
/****** Object:  Table [dbo].[ErrorLog]    Script Date: 04/07/2009 16:41:58 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[ErrorLog](
	[Id] [int] IDENTITY(1,1) NOT NULL,
	[ErrorTypeId] [int] NOT NULL,
	[UserName] [nvarchar](50) COLLATE SQL_Latin1_General_CP1250_CI_AS NULL,
	[DateTime] [datetime] NULL,
	[ErrorDetails] [text] COLLATE SQL_Latin1_General_CP1250_CI_AS NULL,
 CONSTRAINT [PK_ErrorLog] PRIMARY KEY CLUSTERED 
(
	[Id] ASC
) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]

GO
USE [BAZA_REKLAM]
GO
ALTER TABLE [dbo].[ErrorLog]  WITH CHECK ADD  CONSTRAINT [FK_ErrorLog_ErrorType] FOREIGN KEY([ErrorTypeId])
REFERENCES [dbo].[ErrorType] ([Id])