Tables [dbo].[SakariScheduledMessage]
Properties
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
HeapYes
Row Count (~)0
Created7:28:49 PM Thursday, August 29, 2024
Last Modified7:28:49 PM Thursday, August 29, 2024
Columns
NameData TypeMax Length (Bytes)Allow NullsIdentity
Primary Key PK_SakariScheduledMessageID: SakariScheduledMessageIDSakariScheduledMessageIDint4
No
1 - 1
Foreign Keys FK_SakariScheduledMessage_SakariConversation: [dbo].[SakariConversation].SakariConversationFIDSakariConversationFIDint4
No
Foreign Keys FK_SakariScheduledMessage_SakariContact: [dbo].[SakariContact].SakariContactFIDSakariContactFIDint4
No
TextMessagenvarchar(max)max
No
CreatedAtdatetimeoffset10
No
Foreign Keys FK_SakariScheduledMessage_Sysuser: [dbo].[Sysuser].SentBySentByint4
No
Indexes IX_SakariScheduledMessage_ToBeSentAt: ToBeSentAtToBeSentAtdatetimeoffset10
No
ErrorMessagevarchar(512)512
Yes
Indexes Indexes
NameColumnsUnique
Primary Key PK_SakariScheduledMessageID: SakariScheduledMessageIDPK_SakariScheduledMessageIDSakariScheduledMessageID
Yes
IX_SakariScheduledMessage_ToBeSentAtToBeSentAt
Foreign Keys Foreign Keys
NameColumns
FK_SakariScheduledMessage_SakariContactSakariContactFID->[dbo].[SakariContact].[SakariContactID]
FK_SakariScheduledMessage_SakariConversationSakariConversationFID->[dbo].[SakariConversation].[SakariConversationID]
FK_SakariScheduledMessage_SysuserSentBy->[dbo].[Sysuser].[SysUserID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[SakariScheduledMessage]
(
[SakariScheduledMessageID] [int] NOT NULL IDENTITY(1, 1),
[SakariConversationFID] [int] NOT NULL,
[SakariContactFID] [int] NOT NULL,
[TextMessage] [nvarchar] (max) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[CreatedAt] [datetimeoffset] NOT NULL,
[SentBy] [int] NOT NULL,
[ToBeSentAt] [datetimeoffset] NOT NULL,
[ErrorMessage] [varchar] (512) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
ALTER TABLE [dbo].[SakariScheduledMessage] ADD CONSTRAINT [PK_SakariScheduledMessageID] PRIMARY KEY NONCLUSTERED  ([SakariScheduledMessageID]) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_SakariScheduledMessage_ToBeSentAt] ON [dbo].[SakariScheduledMessage] ([ToBeSentAt]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[SakariScheduledMessage] ADD CONSTRAINT [FK_SakariScheduledMessage_SakariContact] FOREIGN KEY ([SakariContactFID]) REFERENCES [dbo].[SakariContact] ([SakariContactID])
GO
ALTER TABLE [dbo].[SakariScheduledMessage] ADD CONSTRAINT [FK_SakariScheduledMessage_SakariConversation] FOREIGN KEY ([SakariConversationFID]) REFERENCES [dbo].[SakariConversation] ([SakariConversationID])
GO
ALTER TABLE [dbo].[SakariScheduledMessage] ADD CONSTRAINT [FK_SakariScheduledMessage_Sysuser] FOREIGN KEY ([SentBy]) REFERENCES [dbo].[Sysuser] ([SysUserID])
GO
GRANT SELECT ON  [dbo].[SakariScheduledMessage] TO [MssExec]
GRANT INSERT ON  [dbo].[SakariScheduledMessage] TO [MssExec]
GRANT DELETE ON  [dbo].[SakariScheduledMessage] TO [MssExec]
GRANT UPDATE ON  [dbo].[SakariScheduledMessage] TO [MssExec]
GO
Uses
Used By