Table of Contents



pears.PersonStatusDivision

Generated schema reference. Regenerate this page from the SQL unload; keep hand-maintained business notes in the narrative namespace.

Columns

Column Type Null Default Comment
PersonStatusDivisionID char(20) NOT NULL
DivisionID char(20) NULL
Status char(4) NOT NULL
Type char(1) NOT NULL

Primary Key

Foreign Keys

Constraint Columns References Delete/update action
Division DivisionID pears.Division (divisionid) ON DELETE CASCADE
status Status, Type pears.status (status, type) NOT NULL; ON DELETE CASCADE

Referenced By

Indexes

Triggers

Original SQL

-- IQX database structure split by table
-- Source: IQXDatabaseStructure - with comments.sql
-- Table: "pears"."PersonStatusDivision"
-- Table comment: 
-- Statement count: 3
 
CREATE TABLE "pears"."PersonStatusDivision" (
    "PersonStatusDivisionID"         CHAR(20) NOT NULL
   ,"DivisionID"                     CHAR(20) NULL
   ,"Status"                         CHAR(4) NOT NULL
   ,"Type"                           CHAR(1) NOT NULL
   ,PRIMARY KEY ("PersonStatusDivisionID" ASC) 
)
GO
 
 
ALTER TABLE "pears"."PersonStatusDivision"
    ADD FOREIGN KEY "Division" ("DivisionID" ASC)
    REFERENCES "pears"."Division" ("divisionid")
    ON DELETE CASCADE
GO
 
 
ALTER TABLE "pears"."PersonStatusDivision"
    ADD NOT NULL FOREIGN KEY "status" ("Status" ASC,"Type" ASC)
    REFERENCES "pears"."status" ("status","type")
    ON DELETE CASCADE
GO