SALESORDERITEMTICKETCOMBINATION

Stores data for a combination of tickets on a sales order.

Primary Key

Primary Key Field Type
ID uniqueidentifier

Fields

Field Field Type Null Notes Description
TICKETCOMBINATIONID uniqueidentifier The combination of tickets
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
ID uniqueidentifier SALESORDERITEMTICKET.ID Primary Key.
COMBINATIONID uniqueidentifier yes COMBINATION.ID The combination of events
PROGRAMGROUPID uniqueidentifier yes PROGRAMGROUP.ID The program group of combination
ADDEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.
CHANGEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.

Indexes

Index Name Fields Unique Primary Clustered
IX_SALESORDERITEMTICKETCOMBINATION_DATEADDED DATEADDED yes
IX_SALESORDERITEMTICKETCOMBINATION_DATECHANGED DATECHANGED
PK_SALESORDERITEMTICKETCOMBINATION ID yes yes
UIX_SALESORDERITEMTICKETCOMBINATION_ID_COMBINATIONID_PROGRAMGROUPID_TICKETCOMBINATIONID ID, COMBINATIONID, PROGRAMGROUPID, TICKETCOMBINATIONID yes

Triggers

Trigger Name Description
TR_SALESORDERITEMTICKETCOMBINATION_AUDIT_UPDATE
TR_SALESORDERITEMTICKETCOMBINATION_AUDIT_DELETE