BATCHREVENUERECOGNITION

Stores recognition credits for batch rows.

Primary Key

Primary Key Field Type
ID uniqueidentifier

Fields

Field Field Type Null Notes Description
CONSTITUENTID uniqueidentifier FK to CONSTITUENT
AMOUNT money Default = 0 Amount a constituent is recognized for.
EFFECTIVEDATE datetime The date a constituent is recognized as having given.
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.
ADDITIONALAPPLICATIONTYPECODE tinyint Default = 255 The type of additional application this recognition is linked to.
APPLICATIONTYPECODE tinyint Default = 255 The type of application this recognition is linked to.
APPLICATIONID uniqueidentifier yes The ID of the application this recognition is linked to.
APPLICATIONTYPE nvarchar(22) (Computed) yes CASE [APPLICATIONTYPECODE] WHEN 1 THEN N'Pledge' WHEN 2 THEN N'Recurring gift' WHEN 3 THEN N'Matching gift claim' WHEN 4 THEN N'Planned gift' WHEN 5 THEN N'Membership' WHEN 6 THEN N'Event registration fee' WHEN 9 THEN N'Grant award' WHEN 255 THEN N'None' END Provides a translation for the 'APPLICATIONTYPECODE' field.
ADDITIONALAPPLICATIONTYPE nvarchar(31) (Computed) yes CASE [ADDITIONALAPPLICATIONTYPECODE] WHEN 0 THEN N'Donation' WHEN 1 THEN N'Other' WHEN 2 THEN N'Unapplied matching gift payment' WHEN 3 THEN N'Additional sponsorship donation' WHEN 255 THEN N'None' END Provides a translation for the 'ADDITIONALAPPLICATIONTYPECODE' field.
REVENUERECOGNITIONID uniqueidentifier yes Recognition id for revenue update batch.
ADDITIONALAPPLICATIONDECLINESGIFTAID bit Default = 0
RECOGNITIONCREDITFKID uniqueidentifier yes Donor challenge encumbered ID or Revenue split ID of recognition credit of donation application matched by donor challenge.
DONORCHALLENGERECOGNITIONTYPECODE tinyint Default = 0 Type of recognition credit of donation application matched by donor challenge
DONORCHALLENGERECOGNITIONTYPE nvarchar(16) (Computed) yes CASE [DONORCHALLENGERECOGNITIONTYPECODE] WHEN 0 THEN N'Original' WHEN 1 THEN N'External sponsor' WHEN 2 THEN N'Internal sponsor' END Provides a translation for the 'DONORCHALLENGERECOGNITIONTYPECODE' field.
RECOGNITIONCREDITDESIGNATIONID uniqueidentifier yes Designation id for recognition credit of donation application matched by donor challenge.
ADDITIONALAPPLICATIONSPONSORSHIPID uniqueidentifier yes

Foreign Keys

Foreign Key Field Type Null Notes Description
BATCHREVENUEID uniqueidentifier BATCHREVENUE.ID Indicates the batch row this soft credit applies to.
REVENUERECOGNITIONTYPECODEID uniqueidentifier yes REVENUERECOGNITIONTYPECODE.ID FK to REVENUERECOGNITIONTYPECODE
ADDEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.
CHANGEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.
ADDITIONALAPPLICATIONDESIGNATIONID uniqueidentifier yes DESIGNATION.ID The designation of the additional application this recognition is linked to.

Indexes

Index Name Fields Unique Primary Clustered
IX_BATCHREVENUERECOGNITION_BATCHREVENUEID BATCHREVENUEID
IX_BATCHREVENUERECOGNITION_CONSTITUENTID CONSTITUENTID
IX_BATCHREVENUERECOGNITION_DATEADDED DATEADDED yes
IX_BATCHREVENUERECOGNITION_DATECHANGED DATECHANGED
PK_BATCHREVENUERECOGNITION ID yes yes

Triggers

Trigger Name Description
TR_BATCHREVENUERECOGNITION_AUDIT_UPDATE
TR_BATCHREVENUERECOGNITION_AUDIT_DELETE