Table: Project_Template_Assignment
Columns
Name | Type | Constraints | Description
project_template_assignment_KEY | int | NOT NULL |
update__staff_KEY | int | NOT NULL |
update_date_utc | datetime | NOT NULL |
create_date_utc | datetime | NOT NULL |
staff_KEY | int | NOT NULL | Which staff is assigned.
project_template_KEY | int | NOT NULL | Which project template this assignment is for.
budgeted_hours | decimal (9, 2) | NOT NULL | Must be greater than or equal to zero, or -1.00 (to indicate assignment only without a budget.)
is_primary_assignment | bit | NOT NULL | Exactly one record per [project_template_KEY] should be set to true.

Primary key
Name | Columns | Description
PK_Project_Template_Assignment$project_template_assignment_KEY | project_template_assignment_KEY | CLUSTERED
Unique constraints
Name | Columns | Description
UK_Project_Template_Assignment$project_template_KEY$staff_KEY | project_template_KEY, staff_KEY |
Indexes
Name | Columns | Description
IX_Project_Template_Assignment$staff_KEY | staff_KEY | Index supports foreign key FK_Project_Template_Assignment__Staff__staff_KEY

Foreign keys
Name | Columns | Referenced table | Description
FK_Project_Template_Assignment__Project_Template__project_template_KEY | project_template_KEY | Project_Template |
FK_Project_Template_Assignment__Staff__staff_KEY | staff_KEY | Staff | on delete cascade;