pears.AutoMatchPersonPreferredShiftType
Generated schema reference. Regenerate this page from the SQL unload; keep hand-maintained business notes in the narrative namespace.
Description
Preferred shift template group
Columns
| Column | Type | Null | Default | Comment |
|---|---|---|---|---|
| AutoMatchPersonPreferredShiftTypeID | char(20) | NOT NULL | ||
| PersonID | char(20) | NULL | ||
| ShiftTemplateGroupID | char(20) | NULL | ||
| Created | timestamp | NULL | current timestamp | |
| Weighting | tinyint | NULL |
Primary Key
- AutoMatchPersonPreferredShiftTypeID
Foreign Keys
| Constraint | Columns | References | Delete/update action |
|---|---|---|---|
| Person | PersonID | pears.Person (personid) | ON DELETE CASCADE |
| ShiftTemplateGroup | ShiftTemplateGroupID | pears.ShiftTemplateGroup (ShiftTemplateGroupID) | ON DELETE CASCADE |
Referenced By
- No incoming foreign keys found.
Indexes
- No indexes found.
Triggers
- No triggers found.
Original SQL
-- IQX database structure split by table -- Source: IQXDatabaseStructure - with comments.sql -- Table: "pears"."AutoMatchPersonPreferredShiftType" -- Table comment: Preferred shift template group -- Statement count: 4 CREATE TABLE "pears"."AutoMatchPersonPreferredShiftType" ( "AutoMatchPersonPreferredShiftTypeID" CHAR(20) NOT NULL ,"PersonID" CHAR(20) NULL ,"ShiftTemplateGroupID" CHAR(20) NULL ,"Created" TIMESTAMP NULL DEFAULT CURRENT TIMESTAMP ,"Weighting" tinyint NULL ,PRIMARY KEY ("AutoMatchPersonPreferredShiftTypeID" ASC) ) GO COMMENT ON TABLE "pears"."AutoMatchPersonPreferredShiftType" IS 'Preferred shift template group' GO ALTER TABLE "pears"."AutoMatchPersonPreferredShiftType" ADD FOREIGN KEY "Person" ("PersonID" ASC) REFERENCES "pears"."Person" ("personid") ON DELETE CASCADE GO ALTER TABLE "pears"."AutoMatchPersonPreferredShiftType" ADD FOREIGN KEY "ShiftTemplateGroup" ("ShiftTemplateGroupID" ASC) REFERENCES "pears"."ShiftTemplateGroup" ("ShiftTemplateGroupID") ON DELETE CASCADE GO