ACTIONITEMMESSAGETEXT

Action Item Message Text

Primary Key

Primary Key Field Type
ID uniqueidentifier

Fields

Field Field Type Null Notes Description
SUBJECT nvarchar(250) Default = '' The Subject of the Message
MESSAGETEXT nvarchar(max) Default = '' The Content of the Message
INSTRUCTIONS nvarchar(1000) Default = '' Instructions for the Message
THANKYOUMESSAGETEXT nvarchar(max) Default = '' This is the text of the thankyou email that will be sent to activists after they take action
SENDCOPYTONPO bit Default = 0 Indicates whether copy of letter is sent to NOP
DATEADDED datetime Default = getdate() Indicates the date this record was added.
DATECHANGED datetime Default = getdate() Indicates the date this record was last changed.
TS timestamp Timestamp.
TSLONG bigint (Computed) yes CONVERT(bigint, TS) Numeric representation of the timestamp.
OVERWRITECODE tinyint Default = 0 Letter Overwrite Type
OVERWRITE nvarchar(16) (Computed) yes CASE [OVERWRITECODE] WHEN 0 THEN N'Cannot Overwrite' WHEN 1 THEN N'Can Overwrite' WHEN 2 THEN N'Must Overwrite' END Provides a translation for the 'OVERWRITECODE' field.
PERSONALIZATIONCODE tinyint Default = 0 Personalization Type
PERSONALIZATION nvarchar(29) (Computed) yes CASE [PERSONALIZATIONCODE] WHEN 0 THEN N'None' WHEN 1 THEN N'Before Message Text' WHEN 2 THEN N'After Message Text' WHEN 3 THEN N'Before and After Message Text' END Provides a translation for the 'PERSONALIZATIONCODE' field.

Foreign Keys

Foreign Key Field Type Null Notes Description
ACTIONITEMID uniqueidentifier ACTION_ITEM.ID Action Item ID
ADDEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.
CHANGEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.
EMAILTEMPLATEID int yes EmailTemplate.ID EmailTemplateID

Indexes

Index Name Fields Unique Primary Clustered
IX_ACTIONITEMMESSAGETEXT_DATEADDED DATEADDED yes
IX_ACTIONITEMMESSAGETEXT_DATECHANGED DATECHANGED
PK_ACTIONITEMMESSAGETEXT ID yes yes
UIX_ACTIONITEMMESSAGETEXT_ACTIONITEMID ACTIONITEMID yes

Triggers

Trigger Name Description
TR_ACTIONITEMMESSAGETEXT_AUDIT_UPDATE
TR_ACTIONITEMMESSAGETEXT_AUDIT_DELETE