SALESORDERPAYMENT (4.0SP14)

Stores payments for a sales order.

Primary Key
Primary Key Field Type

ID

uniqueidentifier

Foreign Key Fields
Foreign Key Field Type Null Notes Description

SALESORDERID

uniqueidentifier

false

The sales order record for this payment.

PAYMENTID

uniqueidentifier

false

The payment record for this sales order.

ADDEDBYID

uniqueidentifier

false

FK to CHANGEAGENT.

CHANGEDBYID

uniqueidentifier

false

FK to CHANGEAGENT.

RECONCILIATIONID

uniqueidentifier

true

The reconciliation record for this payment.

APPUSERID

uniqueidentifier

true

The application user who entered the payment.

Fields
Field Field Type Null Notes Description

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.

AMOUNTTENDERED

money

false

0

The amount tendered for this payment.

AMOUNT

money

false

0

The actual amount of the payment.

CHANGEDUE

money

false

0

The change due for this payment.

PAYMENTDATEWITHTIMEOFFSET

datetimeoffset

true

The date the payment was made with time zone awareness.

DONOTRECONCILE

bit

false

0

Determines whether the payment should be reconciled.

DEPOSITED

bit

false

0

Indexes
Index Name Field(s) Unique Primary Clustered

IX_SALESORDERPAYMENT_APPUSERID

APPUSERID

False

False

False

IX_SALESORDERPAYMENT_DATEADDED

DATEADDED

False

False

True

IX_SALESORDERPAYMENT_DATECHANGED

DATECHANGED

False

False

False

IX_SALESORDERPAYMENT_PAYMENTID

PAYMENTID

False

False

False

IX_SALESORDERPAYMENT_RECONCILIATIONID

RECONCILIATIONID

False

False

False

IX_SALESORDERPAYMENT_SALESORDERID

SALESORDERID

False

False

False

PK_SALESORDERPAYMENT

ID

True

True

False

Triggers
Trigger Name Description

TR_SALESORDERPAYMENT_AUDIT_UPDATE

TR_SALESORDERPAYMENT_AUDIT_DELETE