Primary Key Field Type
 ID uniqueidentifier

Field Field Type Null Notes Description
 PROMOTIONALCODE nvarchar(50)   Default = '' The Promotion Code for the discount.
 VALIDFROM datetime Valid from date for the promotion code.
 VALIDTO datetime Valid to date for the promotion code.
 SEQUENCE int   Default = 0 The sequence in which promotion codes are entered.
 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.

Foreign Key Field Type Null Notes Description
 MEMBERSHIPPROMOID uniqueidentifier   MEMBERSHIPPROMO.ID The ID of the Membership Promotion the Promotion Code belongs to.
 ADDEDBYID uniqueidentifier   CHANGEAGENT.ID FK to CHANGEAGENT.
 CHANGEDBYID uniqueidentifier   CHANGEAGENT.ID FK to CHANGEAGENT.

Index Name Field(s) Unique Primary Clustered
 IX_MEMBERSHIPPROMOCODE_DATEADDED DATEADDED    
 IX_MEMBERSHIPPROMOCODE_DATECHANGED DATECHANGED      
 IX_MEMBERSHIPPROMOCODE_PROMOTIONALCODE PROMOTIONALCODE      
 PK_MEMBERSHIPPROMOCODE ID  
 UC_MEMBERSHIPPROMOCODE_PROMOTIONALCODE PROMOTIONALCODE    

Trigger Name Description
 TR_MEMBERSHIPPROMOCODE_AUDIT_UPDATE
 TR_MEMBERSHIPPROMOCODE_AUDIT_DELETE

Entity-Relationship diagram of this table