ADJUSTMENTHISTORYDETAIL (4.0)

Stores detail information on historic adjustments.

Primary Key
Primary Key Field Type

ID

uniqueidentifier

Foreign Key Fields
Foreign Key Field Type Null Notes Description

ADJUSTMENTHISTORYID

uniqueidentifier

false

Indicates the history item to which this detail belongs.

ADDEDBYID

uniqueidentifier

false

FK to CHANGEAGENT.

CHANGEDBYID

uniqueidentifier

false

FK to CHANGEAGENT.

BASECURRENCYID

uniqueidentifier

true

The base currency associated with this adjustment.

TRANSACTIONCURRENCYID

uniqueidentifier

true

The transaction currency associated with this adjustment.

Fields
Field Field Type Null Notes Description

ADJUSTEDFIELD

nvarchar(100)

false

''

Indicates the field that caused the adjustment.

ADJUSTEDFIELDPREVIOUSVALUE

nvarchar(max)

false

''

Indicates the value of the adjusted field before the adjustment.

ADJUSTEDFIELDADJUSTEDVALUE

nvarchar(max)

false

''

Indicates the value of the adjusted field after the adjustment.

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.

ISMONEY

bit

false

0

Indicates whether or not the adjustment was for a monetary value.

ADJUSTEDFIELDPREVIOUSMONEYVALUE

money

false

0

Indicates the value of the adjusted money field before the adjustment.

ADJUSTEDFIELDADJUSTEDMONEYVALUE

money

false

0

Indicates the value of the adjusted money field after the adjustment.

TRANSACTIONADJUSTEDFIELDPREVIOUSVALUE

nvarchar(max)

false

''

Indicates the value of the adjusted field before the adjustment in transaction currency.

TRANSACTIONADJUSTEDFIELDADJUSTEDVALUE

nvarchar(max)

false

''

Indicates the value of the adjusted field after the adjustment in transaction currency.

TRANSACTIONADJUSTEDFIELDPREVIOUSMONEYVALUE

money

false

0

Indicates the value of the adjusted money field before the adjustment in transaction currency.

TRANSACTIONADJUSTEDFIELDADJUSTEDMONEYVALUE

money

false

0

Indicates the value of the adjusted money field after the adjustment in transaction currency.

ORGANIZATIONADJUSTEDFIELDPREVIOUSVALUE

nvarchar(max)

false

''

Indicates the value of the adjusted field before the adjustment in organization currency.

ORGANIZATIONADJUSTEDFIELDADJUSTEDVALUE

nvarchar(max)

false

''

Indicates the value of the adjusted field after the adjustment in organization currency.

ORGANIZATIONADJUSTEDFIELDPREVIOUSMONEYVALUE

money

false

0

Indicates the value of the adjusted money field before the adjustment in organization currency.

ORGANIZATIONADJUSTEDFIELDADJUSTEDMONEYVALUE

money

false

0

Indicates the value of the adjusted money field after the adjustment in organization currency.

Indexes
Index Name Field(s) Unique Primary Clustered

IX_ADJUSTMENTHISTORYDETAIL_DATEADDED

DATEADDED

False

False

True

IX_ADJUSTMENTHISTORYDETAIL_DATECHANGED

DATECHANGED

False

False

False

PK_ADJUSTMENTHISTORYDETAIL

ID

True

True

False

Triggers
Trigger Name Description

TR_ADJUSTMENTHISTORYDETAIL_AUDIT_UPDATE

TR_ADJUSTMENTHISTORYDETAIL_AUDIT_DELETE