MERCHANDISEDEPARTMENT (4.0SP14)

A department to which specific merchandise items belong.

Primary Key
Primary Key Field Type

ID

uniqueidentifier

Foreign Key Fields
Foreign Key Field Type Null Notes Description

ADDEDBYID

uniqueidentifier

false

FK to CHANGEAGENT.

CHANGEDBYID

uniqueidentifier

false

FK to CHANGEAGENT.

Fields
Field Field Type Null Notes Description

NAME

nvarchar(100)

false

''

The department name.

DESCRIPTION

nvarchar(255)

false

''

The department 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.

ISACTIVE

bit

false

1

Determines whether the department is active.

ISDISCOUNTABLE

bit

false

1

Determines whether merchandise items belong to this department can be discounted.

Indexes
Index Name Field(s) Unique Primary Clustered

IX_MERCHANDISEDEPARTMENT_DATEADDED

DATEADDED

False

False

True

IX_MERCHANDISEDEPARTMENT_DATECHANGED

DATECHANGED

False

False

False

PK_MERCHANDISEDEPARTMENT

ID

True

True

False

UC_MERCHANDISEDEPARTMENT_NAME

NAME

True

False

False

Triggers
Trigger Name Description

TR_MERCHANDISEDEPARTMENT_AUDIT_UPDATE

TR_MERCHANDISEDEPARTMENT_AUDIT_DELETE

Referenced by
Referenced by Field

DISCOUNTGROUPDETAILMERCHANDISEDEPARTMENT

MERCHANDISEDEPARTMENTID

MERCHANDISEDEPARTMENTCATEGORY

MERCHANDISEDEPARTMENTID

MERCHANDISEPRODUCT

MERCHANDISEDEPARTMENTID

SALESORDERITEMMERCHANDISE

MERCHANDISEDEPARTMENTID