ADDSTEWARDSHIPPLANSPROCESS

Add stewardship plans process parameters.

Primary Key

Primary Key Field Type
ID uniqueidentifier

Fields

Field Field Type Null Notes Description
NAME nvarchar(100) Default = '' The name of the parameter set.
DESCRIPTION nvarchar(255) Default = '' Details describing this parameter set
PROSPECTPLANNAME nvarchar(100) Default = ''
STARTDATETYPECODE tinyint Default = 0 0=Date this process runs, 1=Specific date, 2=X days after this process runs, 3=X days before this process runs
STARTDATETYPE nvarchar(31) (Computed) yes CASE [STARTDATETYPECODE] WHEN 0 THEN N'Date this process runs' WHEN 1 THEN N'Specific date' WHEN 2 THEN N'X days after this process runs' WHEN 3 THEN N'X days before this process runs' END Provides a translation for the 'STARTDATETYPECODE' field.
STARTDATE date yes
DAYSBEFOREORAFTER int Default = 0
PLANSTEPS xml yes Contains the steps to be associated with the plan.
STEWARDS xml yes Contains the stewards to be associated with the plan.
SITES xml yes Contains the sites to be associated with the plan.
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.
MANAGERSTARTDATE date yes

Foreign Keys

Foreign Key Field Type Null Notes Description
IDSETREGISTERID uniqueidentifier yes IDSETREGISTER.ID Selection of constituents to have plans and steps added.
PLANTYPECODEID uniqueidentifier yes STEWARDSHIPPLANTYPECODE.ID The plan type for this stewardship plan.
PLANSUBTYPECODEID uniqueidentifier yes STEWARDSHIPPLANSUBTYPECODE.ID The plan subtype for this stewardship plan.
MANAGERID uniqueidentifier yes CONSTITUENT.LOCALID FK to CONSTITUENT
ADDEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.
CHANGEDBYID uniqueidentifier CHANGEAGENT.ID FK to CHANGEAGENT.

Indexes

Index Name Fields Unique Primary Clustered
IX_ADDSTEWARDSHIPPLANSPROCESS_DATEADDED DATEADDED yes
IX_ADDSTEWARDSHIPPLANSPROCESS_DATECHANGED DATECHANGED
IX_ADDSTEWARDSHIPPLANSPROCESS_IDSETREGISTERID IDSETREGISTERID
IX_ADDSTEWARDSHIPPLANSPROCESS_MANAGERID MANAGERID
IX_ADDSTEWARDSHIPPLANSPROCESS_PLANTYPECODEID PLANTYPECODEID
PK_ADDSTEWARDSHIPPLANSPROCESS ID yes yes
UC_ADDSTEWARDSHIPPLANSPROCESS_NAME NAME yes

Triggers

Trigger Name Description
TR_ADDSTEWARDSHIPPLANSPROCESS_AUDIT_UPDATE
TR_ADDSTEWARDSHIPPLANSPROCESS_AUDIT_DELETE

Referenced by

Referenced by Field
ADDSTEWARDSHIPPLANSPROCESSSTATUS PARAMETERSETID