Primary Key Field Type
 ID uniqueidentifier

Field Field Type Null Notes Description
 MEMBERSHIPPROMONAME nvarchar(100)   Default = '' Name of promotion at time of sale.
 EXTENSIONCALCULATIONTYPECODE tinyint   Default = 0 The type of term extension: 0 - Day, 1 - Month
 EXTENSIONCALCULATIONTYPE nvarchar(12) (Computed) CASE [EXTENSIONCALCULATIONTYPECODE] WHEN 0 THEN N'Days added' WHEN 1 THEN N'Months added' END Provides a translation for the 'EXTENSIONCALCULATIONTYPECODE' field.
 EXTENSIONVALUE int   Default = 0 The number of days/months to extend the term by.
 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) CONVERT(bigint, TS) Numeric representation of the timestamp.
 PROMOTIONALCODE nvarchar(50)   Default = '' The Promotion Code used to apply the discount.
 INUSE bit   Default = 0 Indicates this promo is being applied to the order

Foreign Key Field Type Null Notes Description
 ID uniqueidentifier   SALESORDERITEM.ID Primary Key.
 MEMBERSHIPPROMOID uniqueidentifier   MEMBERSHIPPROMO.ID Membership promotion being applied to the order
 ADDEDBYID uniqueidentifier   CHANGEAGENT.ID FK to CHANGEAGENT.
 CHANGEDBYID uniqueidentifier   CHANGEAGENT.ID FK to CHANGEAGENT.

Index Name Field(s) Unique Primary Clustered
 IX_SALESORDERITEMMEMBERSHIPPROMO_DATEADDED DATEADDED    
 IX_SALESORDERITEMMEMBERSHIPPROMO_DATECHANGED DATECHANGED      
 PK_SALESORDERITEMMEMBERSHIPPROMO ID  

Trigger Name Description
 TR_SALESORDERITEMMEMBERSHIPPROMO_AUDIT_UPDATE
 TR_SALESORDERITEMMEMBERSHIPPROMO_AUDIT_DELETE

Entity-Relationship diagram of this table