====== pears.externalemployment ====== Generated schema reference. Regenerate this page from the SQL unload; keep hand-maintained business notes in the narrative namespace. ===== Description ===== Employment for temps when the company doesn't exist in IQX. ===== Columns ===== ^ Column ^ Type ^ Null ^ Default ^ Comment ^ | **extemploymentid** | char(20) | NOT NULL | | | | personid | char(20) | NOT NULL | | | | companyname | char(50) | NULL | | | | startdate | date | NULL | | | | leavedate | date | NULL | | | | temp | smallint | NULL | 0 | | | note | char(100) | NULL | | | | salary | numeric(12,2) | NULL | | | | position | char(50) | NULL | | | | ExtendedNotes | long varchar | NULL | | | | noreemploy | smallint | NULL | 0 | | | Concurrent | smallint | NULL | 0 | | ===== Primary Key ===== * extemploymentid ===== Foreign Keys ===== ^ Constraint ^ Columns ^ References ^ Delete/update action ^ | person | personid | [[database:tables:pears_person|pears.Person (personid)]] | NOT NULL; | ===== 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"."externalemployment" -- Table comment: Employment for temps when the company doesn't exist in IQX. -- Statement count: 3 CREATE TABLE "pears"."externalemployment" ( "extemploymentid" char(20) NOT NULL ,"personid" char(20) NOT NULL ,"companyname" char(50) NULL ,"startdate" date NULL ,"leavedate" date NULL ,"temp" smallint NULL DEFAULT 0 ,"note" char(100) NULL ,"salary" numeric(12,2) NULL ,"position" char(50) NULL ,"ExtendedNotes" long varchar NULL ,"noreemploy" smallint NULL DEFAULT 0 ,"Concurrent" smallint NULL DEFAULT 0 ,PRIMARY KEY ("extemploymentid" ASC) ) go COMMENT ON TABLE "pears"."externalemployment" IS 'Employment for temps when the company doesn''t exist in IQX.' go ALTER TABLE "pears"."externalemployment" ADD NOT NULL FOREIGN KEY "person" ("personid" ASC) REFERENCES "pears"."Person" ("personid") go