STEWARDSHIPATTACHMENT (4.0SP17)

This table contains attachments belonging to stewardship plans and steps.

Primary Key
Primary Key Field Type

ID

uniqueidentifier

Foreign Key Fields
Foreign Key Field Type Null Notes Description

AUTHORID

uniqueidentifier

true

The author of the attachment.

PLANID

uniqueidentifier

true

The stewardship plan to which this note belongs.

STEPID

uniqueidentifier

true

The stewardship step to which this attachment belongs.

STEWARDSHIPATTACHMENTTYPECODEID

uniqueidentifier

false

FK to STEWARDSHIPATTACHMENTTYPECODE

ENTEREDBYAPPUSERID

uniqueidentifier

true

FK to APPUSER

ADDEDBYID

uniqueidentifier

false

FK to CHANGEAGENT.

CHANGEDBYID

uniqueidentifier

false

FK to CHANGEAGENT.

Fields
Field Field Type Null Notes Description

DATEENTERED

datetime

false

The date the attachment was entered.

TITLE

nvarchar(100)

false

''

The title of the attachment.

FILENAME

nvarchar(255)

false

''

The original file name for the attachment.

FILE

varbinary

false

The actual file for the attachment.

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.

Indexes
Index Name Field(s) Unique Primary Clustered

IX_STEWARDSHIPATTACHMENT_AUTHORID

AUTHORID

False

False

False

IX_STEWARDSHIPATTACHMENT_DATEADDED

DATEADDED

False

False

True

IX_STEWARDSHIPATTACHMENT_DATECHANGED

DATECHANGED

False

False

False

IX_STEWARDSHIPATTACHMENT_STEPID

STEPID

False

False

False

PK_STEWARDSHIPATTACHMENT

ID

True

True

False

Triggers
Trigger Name Description

TR_STEWARDSHIPATTACHMENT_AUDIT_UPDATE

TR_STEWARDSHIPATTACHMENT_AUDIT_DELETE