IF NOT EXISTS (SELECT * FROM dbo.sysobjects WHERE id = object_id(N'[dbo].[OTAInvCountNotifHallLog]') AND OBJECTPROPERTY(id, N'IsUserTable') = 1)
BEGIN
  CREATE TABLE [dbo].OTAInvCountNotifHallLog(
	[FKConferenceRoomTypeNumber] [int] NOT NULL,
	[FromDatetime] [datetime] NOT NULL,
	[ToDatetime] [datetime] NOT NULL,
	[NumberOfHalls] [int] NULL,
	[SubmitDatestamp] [datetime] NULL,
 CONSTRAINT [PK_OTAInvCountNotifHallLog] PRIMARY KEY CLUSTERED 
(
	[FKConferenceRoomTypeNumber] ASC,
	[FromDatetime] ASC,
	[ToDatetime] ASC
)  ) ON [PRIMARY]
END
