SALESORDERITEMMEMBERSHIPITEMPROMOTION (4.0SP14)

Stores the item membership promotion.

Primary Key
Primary Key Field Type

ID

uniqueidentifier

Foreign Key Fields
Foreign Key Field Type Null Notes Description

SALESORDERITEMID

uniqueidentifier

false

Sales order item with item promotion

ADDEDBYID

uniqueidentifier

false

FK to CHANGEAGENT.

CHANGEDBYID

uniqueidentifier

false

FK to CHANGEAGENT.

MEMBERSHIPPROMOID

uniqueidentifier

true

Promotion being used

ORGANIZATIONEXCHANGERATEID

uniqueidentifier

true

The exchange rate used to convert from amount to organization amount.

BASECURRENCYID

uniqueidentifier

true

The base currency associated with this item membership promotion.

Fields
Field Field Type Null Notes Description

PROMOTIONNAME

nvarchar(100)

false

''

Name of promotion at time of sale.

AMOUNT

money

false

0

Amount of the promotion

DATEADDED

datetime

false

getdate()

Indicates the date this record was added.

DATECHANGED

datetime

false

getdate()

Indicates the date this record was last changed.

TS

timestamp

false

Timestamp.

TSLONG

bigint (Computed)

true

Numeric representation of the timestamp.

EXTENSIONCALCULATIONTYPECODE

tinyint

false

0

The type of term extension: 0 - Day, 1 - Month

EXTENSIONCALCULATIONTYPE

nvarchar(12) (Computed)

true

Provides a translation for the 'EXTENSIONCALCULATIONTYPECODE' field.

EXTENSIONVALUE

int

false

0

The number of days/months to extend the term by.

ORGANIZATIONAMOUNT

money

false

0

Amount of promotion in organization currency.

Indexes
Index Name Field(s) Unique Primary Clustered

IX_SALESORDERITEMMEMBERSHIPITEMPROMOTION_BASECURRENCYID

BASECURRENCYID

False

False

False

IX_SALESORDERITEMMEMBERSHIPITEMPROMOTION_DATEADDED

DATEADDED

False

False

True

IX_SALESORDERITEMMEMBERSHIPITEMPROMOTION_DATECHANGED

DATECHANGED

False

False

False

IX_SALESORDERITEMMEMBERSHIPITEMPROMOTION_ORGANIZATIONEXCHANGERATEID

ORGANIZATIONEXCHANGERATEID

False

False

False

IX_SALESORDERITEMMEMBERSHIPITEMPROMOTION_SALESORDERITEMID

SALESORDERITEMID

False

False

False

PK_SALESORDERITEMMEMBERSHIPITEMPROMOTION

ID

True

True

False

Triggers
Trigger Name Description

TR_SALESORDERITEMMEMBERSHIPITEMPROMOTION_AUDIT_UPDATE

TR_SALESORDERITEMMEMBERSHIPITEMPROMOTION_AUDIT_DELETE

TR_SALESORDERITEMMEMBERSHIPITEMPROMOTION_INSERTUPDATE_CURRENCY

Referenced by
Referenced by Field

CREDITITEM_EXT

SALESORDERITEMMEMBERSHIPITEMPROMOTIONID

CREDITITEMMEMBERSHIPITEMPROMOTION

SALESORDERITEMMEMBERSHIPITEMPROMOTIONID

SALESORDERITEMMEMBERSHIPITEMPROMOTIONAPPLIEDITEM

SALESORDERITEMMEMBERSHIPITEMPROMOTIONID