SALESORDERITEMTAX
Stores data for a tax on a sales order.
Primary Key
| Primary Key |
Field Type |
| ID |
uniqueidentifier |
Fields
| Field |
Field Type |
Null |
Notes |
Description |
| 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. |
| TOTALTAX |
decimal(7, 4) |
|
Default = 0 |
The totaltax applied to the item when the order is completed. |
| TAXNAME |
nvarchar(100) |
|
Default = '' |
Name of tax at time of sale. |
Foreign Keys
| Foreign Key |
Field Type |
Null |
Notes |
Description |
| TAXID |
uniqueidentifier |
yes |
TAX.ID
|
The tax in which the order item tax is linked. |
| SALESORDERITEMID |
uniqueidentifier |
yes |
SALESORDERITEM.ID
|
The sales order item to which the tax applies. |
| TAXITEMID |
uniqueidentifier |
yes |
SALESORDERITEM.ID
|
The sales order item that contains the tax information. |
| ADDEDBYID |
uniqueidentifier |
|
CHANGEAGENT.ID
|
FK to CHANGEAGENT. |
| CHANGEDBYID |
uniqueidentifier |
|
CHANGEAGENT.ID
|
FK to CHANGEAGENT. |
Indexes
| Index Name |
Fields |
Unique |
Primary |
Clustered |
| IX_SALESORDERITEMTAX_DATEADDED |
DATEADDED |
|
|
yes |
| IX_SALESORDERITEMTAX_DATECHANGED |
DATECHANGED |
|
|
|
| IX_SALESORDERITEMTAX_SALESORDERITEMID |
SALESORDERITEMID |
|
|
|
| IX_SALESORDERITEMTAX_TAXITEMID |
TAXITEMID |
|
|
|
| PK_SALESORDERITEMTAX |
ID |
yes |
yes |
|
Triggers