Table: Activity_Category
Columns
NameTypeConstraintsDescription
activity_category_KEYintNOT NULLAUTO-INCREMENT: Database assigned primary key for this table
update__staff_KEYintNOT NULL
update_date_utcdatetimeNOT NULL
activity_category_idnvarchar (11)NOT NULLUser defined identifier (unique).
descriptionnvarchar (250)NOT NULLUser Defined description
create_date_utcdatetimeNOT NULL
activity_category_id_sortablevarchar (48)NOT NULLA representation of the activity_category_id column that sorts in natural order, meaning that digits are sorted as numbers while non-digits are sorted alphabetically. A trigger keeps this field synchronized with the content of activity_category_id.
long_descriptionnvarchar (-1)NOT NULL
Primary key
NameColumnsDescription
PK_Activity_Category$activity_category_KEYactivity_category_KEYCLUSTERED
Unique constraints
NameColumnsDescription
UK_Activity_Category$activity_category_idactivity_category_idEach id must be unique.
UK_Activity_Category$activity_category_id_sortableactivity_category_id_sortableAn index by the sortable ID is desired, and the algorithm ends up producing unique values.
Incoming foreign keys
NameColumnsReferencing tableDescription
FK_Activity__Activity_Category__activity_category_KEYactivity_category_KEYActivity

Schema diagram