FAFCOMMENTS

Table containing FAF user comments

Primary Key

Primary Key Field Type
ID uniqueidentifier

Fields

Field Field Type Null Notes Description
AUTHORNAME nvarchar(255) Default = '' Full name of the comment author
COMMENTTEXT nvarchar(1000) Default = '' Full text of the posted comment
LIKECOUNT int Default = 0 Count how many people like this comment
DISLIKECOUNT int Default = 0 Count how many people not like this comment
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.

Foreign Keys

Foreign Key Field Type Null Notes Description
EVENTID uniqueidentifier EVENT.ID The id of the event this comment was made in
TEAMFUNDRAISINGTEAMID uniqueidentifier yes TEAMFUNDRAISINGTEAM.ID FK to TEAMFUNDRAISINGTEAM
REGISTRANTID uniqueidentifier yes REGISTRANT.ID FK to REGISTRANT
CLIENTUSERSID int yes ClientUsers.ID Login ID of the User
ADDEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.
CHANGEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.
ROOTCOMMENTID uniqueidentifier yes FAFCOMMENTS.ID Root Comment

Indexes

Index Name Fields Unique Primary Clustered
IX_FAFCOMMENTS_DATEADDED DATEADDED yes
IX_FAFCOMMENTS_DATECHANGED DATECHANGED
IX_FAFCOMMENTS_EVENTID_REGISTRANTID EVENTID, REGISTRANTID
PK_FAFCOMMENTS ID yes yes

Triggers

Trigger Name Description
TR_FAFCOMMENTS_AUDIT_UPDATE
TR_FAFCOMMENTS_AUDIT_DELETE

Referenced by

Referenced by Field
FAFCOMMENTSAPPROVAL COMMENTID