Table: Contact_Category
Columns
NameTypeConstraintsDescription
contact_category_KEYintNOT NULLAUTO-INCREMENT: Database assigned primary key for this table.
update__staff_KEYintNOT NULL
contact_category_idnvarchar (11)NOT NULLUser defined identifier (unique).
descriptionnvarchar (250)NOT NULLUser defined description.
contact_category_id_sortablevarchar (48)NOT NULLA representation of the contact_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 contact_category_id.
create__changeset_KEYintNOT NULL
update__changeset_KEYintNOT NULL
Primary key
NameColumnsDescription
PK_Contact_Category$contact_category_KEYcontact_category_KEYCLUSTERED
Unique constraints
NameColumnsDescription
UK_Contact_Category$contact_category_idcontact_category_idEach id must be unique.
UK_Contact_Category$contact_category_id_sortablecontact_category_id_sortableAn index by the sortable ID is desired, and the algorithm ends up producing unique values.
Incoming foreign keys
NameColumnsReferencing tableDescription
FK_Contact_Contact_Category__Contact_Category__contact_category_KEYcontact_category_KEYContact_Contact_Category

Schema diagram