Table: Benefit_Factor
Columns
NameTypeConstraintsDescription
benefit_factor_KEYintNOT NULLAssigned by COMMON_dp_Allocate_Unique_Identifiers. Primary key for this table, same value as activity_KEY.
update__staff_KEYintNOT NULL
update_date_utcdatetimeNOT NULL
create_date_utcdatetimeNOT NULL
benefit_KEYintNOT NULLKey to a Benefit that the benefit factor is for.
benefit_entry_type_KEYintNOT NULLKey to a benefit entry type that this benefit factor is.
factordecimal (9, 2)NOT NULLThe allowance benefit factor.
to_monthintNOT NULLThe end month of this benefit factor.
to_dayintNOT NULLThe end day of this benefit factor.
sortable_to_datesmalldatetimeNOT NULLThe [to_month] and [to_day] columns are combined into the [sortable_to_date] column for sorting and comparison. The year 2000 was selected as the year to base this date on because it is a leap year and it is a nice even number.
Primary key
NameColumnsDescription
PK_Benefit_Factor$benefit_factor_KEYbenefit_factor_KEYCLUSTERED
Unique constraints
NameColumnsDescription
UK_Benefit_Factor$benefit_KEY$benefit_entry_type_KEY$to_month$to_daybenefit_KEY, benefit_entry_type_KEY, to_month, to_day
Indexes
NameColumnsDescription
IX_Benefit_Factor$benefit_entry_type_KEYbenefit_entry_type_KEYIndex supports foreign key FK_Benefit_Factor__Benefit_Entry_Type__benefit_entry_type_KEY
IX_Benefit_Factor$sortable_to_datesortable_to_date
Foreign keys
NameColumnsReferenced tableDescription
FK_Benefit_Factor__Benefit__benefit_KEYbenefit_KEYBenefiton delete cascade;

Schema diagram