SPONSORSHIPCOMMITMENT

A commitment represents a history of continuous sponsorships for a constituent.

Primary Key

Primary Key Field Type
ID uniqueidentifier

Fields

Field Field Type Null Notes Description
COMMITMENTSEQUENCE smallint Default = ((0)) For ordering a constituent's commitments.
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.
CUSTOMIDENTIFIER nvarchar(100) Default = '' User-definable custom identifier.
SEQUENCEID int Identity column used to increment the default lookupid.
LOOKUPID nvarchar(100) (Computed) yes (CASE LEN(CUSTOMIDENTIFIER) WHEN 0 THEN 'sp-' + CAST(SEQUENCEID AS nvarchar(20)) ELSE CUSTOMIDENTIFIER END) Unique identifier that supports user defined values as well as system generated values.

Foreign Keys

Foreign Key Field Type Null Notes Description
CONSTITUENTID uniqueidentifier CONSTITUENT.LOCALID The constituent for this commitment.
ADDEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.
CHANGEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.

Indexes

Index Name Fields Unique Primary Clustered
IX_SPONSORSHIPCOMMITMENT_DATEADDED DATEADDED yes
IX_SPONSORSHIPCOMMITMENT_DATECHANGED DATECHANGED
PK_SPONSORSHIPCOMMITMENT ID yes yes
UC_SPONSORSHIPCOMMITMENT_LOOKUPID LOOKUPID yes
UIX_SPONSORSHIPCOMMITMENT_CONSTITUENTID_COMMITMENTSEQUENCE CONSTITUENTID, COMMITMENTSEQUENCE yes

Triggers

Trigger Name Description
TR_SPONSORSHIPCOMMITMENT_AUDIT_UPDATE
TR_SPONSORSHIPCOMMITMENT_AUDIT_DELETE

Referenced by

Referenced by Field
SPONSORSHIP SPONSORSHIPCOMMITMENTID
SPONSORSHIPTRANSACTION SPONSORSHIPCOMMITMENTID