DISCOUNTAVAILABILITY
Stores availability for discount.
Primary Key
Primary Key |
Field Type |
ID |
uniqueidentifier |
Fields
Field |
Field Type |
Null |
Notes |
Description |
ALLOWMONDAY |
bit |
|
Default = 1 |
Indicates if the discount is available on Mondays. |
ALLOWTUESDAY |
bit |
|
Default = 1 |
Indicates if the discount is available on Tuesdays. |
ALLOWWEDNESDAY |
bit |
|
Default = 1 |
Indicates if the discount is available on Wednesdays. |
ALLOWFRIDAY |
bit |
|
Default = 1 |
Indicates if the discount is available on Fridays. |
ALLOWSATURDAY |
bit |
|
Default = 1 |
Indicates if the discount is available on Saturdays. |
ALLOWSUNDAY |
bit |
|
Default = 1 |
Indicates if the discount is available on Sundays. |
ALLOWDISCOUNTDATEFROM |
date |
yes |
|
Indicates the beginning date the discount is valid. |
ALLOWDISCOUNTDATETO |
date |
yes |
|
Indicates the end date the discount is valid. |
ALLOWDISCOUNTTIMEFROM |
UDT_HOURMINUTE |
|
Default = '' |
Indicates the beginning time of day the discount is valid. |
ALLOWDISCOUNTTIMETO |
UDT_HOURMINUTE |
|
Default = '' |
Indicates the end time of day the discount is valid. |
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. |
ALLOWTHURSDAY |
bit |
|
Default = 1 |
Indicates if the discount is available on Thursdays. |
SEQUENCE |
int |
|
Default = 0 |
The sequence for availability records. |
Foreign Keys
Foreign Key |
Field Type |
Null |
Notes |
Description |
DISCOUNTID |
uniqueidentifier |
|
DISCOUNT.ID
|
The ID of the Discount the Price Type belongs to. |
ADDEDBYID |
uniqueidentifier |
|
CHANGEAGENT.ID
|
FK to CHANGEAGENT. |
CHANGEDBYID |
uniqueidentifier |
|
CHANGEAGENT.ID
|
FK to CHANGEAGENT. |
Indexes
Index Name |
Fields |
Unique |
Primary |
Clustered |
IX_DISCOUNTAVAILABILITY_DATEADDED |
DATEADDED |
|
|
yes |
IX_DISCOUNTAVAILABILITY_DATECHANGED |
DATECHANGED |
|
|
|
IX_DISCOUNTAVAILABILITY_DISCOUNTID |
DISCOUNTID |
|
|
|
PK_DISCOUNTAVAILABILITY |
ID |
yes |
yes |
|
Triggers
Referenced by