CREATE TABLE [dbo].[AdvanceBatch]
(
[AdvanceBatchID] [int] NOT NULL IDENTITY(1, 1),
[GeneratedDate] [datetime] NULL,
[GeneratedBySysuserFID] [int] NULL,
[AdvanceBatch] [varchar] (max) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
ALTER TABLE [dbo].[AdvanceBatch] ADD CONSTRAINT [PK_AdvanceBatch] PRIMARY KEY CLUSTERED ([AdvanceBatchID]) WITH (FILLFACTOR=80) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_AdvanceBatch_GeneratedBySysuserFID] ON [dbo].[AdvanceBatch] ([GeneratedBySysuserFID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[AdvanceBatch] ADD CONSTRAINT [FK_AdvanceBatch_GeneratedBySysuser] FOREIGN KEY ([GeneratedBySysuserFID]) REFERENCES [dbo].[Sysuser] ([SysUserID])
GO
GRANT SELECT ON [dbo].[AdvanceBatch] TO [MssExec]
GRANT INSERT ON [dbo].[AdvanceBatch] TO [MssExec]
GRANT DELETE ON [dbo].[AdvanceBatch] TO [MssExec]
GRANT UPDATE ON [dbo].[AdvanceBatch] TO [MssExec]
GO