Show pageOld revisionsBacklinksExport to PDFFold/unfold allBack to top This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. ====== pears.WPKLayoutViewStaff ====== <WRAP center round info> Generated schema reference. Regenerate this page from the SQL unload; keep hand-maintained business notes in the narrative namespace. </WRAP> ===== Columns ===== ^ Column ^ Type ^ Null ^ Default ^ Comment ^ | **WPKLayoutID** | char(20) | NOT NULL | | | | **WPKViewID** | char(50) | NOT NULL | | | | **WPKFormID** | char(50) | NOT NULL | | | | **StaffID** | char(20) | NOT NULL | | | | NewSortOrder | smallint | NULL | | | ===== Primary Key ===== * WPKLayoutID, WPKViewID, WPKFormID, StaffID ===== Foreign Keys ===== ^ Constraint ^ Columns ^ References ^ Delete/update action ^ | Layout | WPKLayoutID, WPKFormID | [[database:tables:pears_wpklayout|pears.WPKLayout (WPKLayoutID, WPKFormID)]] | NOT NULL; ON DELETE CASCADE | | ViewK | WPKViewID, WPKFormID | [[database:tables:pears_wpkview|pears.WPKView (WPKViewID, WPKFormID)]] | NOT NULL; ON DELETE CASCADE | ===== Referenced By ===== * No incoming foreign keys found. ===== Indexes ===== * No indexes found. ===== Triggers ===== ^ Name ^ Timing ^ Event ^ | TrackLViewStaffChange | after | insert,delete,update order 1 | ===== Original SQL ===== <code sql> -- IQX database structure split by table -- Source: IQXDatabaseStructure - with comments.sql -- Table: "pears"."WPKLayoutViewStaff" -- Table comment: -- Statement count: 5 CREATE TABLE "pears"."WPKLayoutViewStaff" ( "WPKLayoutID" char(20) NOT NULL ,"WPKViewID" char(50) NOT NULL ,"WPKFormID" char(50) NOT NULL ,"StaffID" char(20) NOT NULL ,"NewSortOrder" smallint NULL ,PRIMARY KEY ("WPKLayoutID" ASC,"WPKViewID" ASC,"WPKFormID" ASC,"StaffID" ASC) ) go ALTER TABLE "pears"."WPKLayoutViewStaff" ADD NOT NULL FOREIGN KEY "Layout" ("WPKLayoutID" ASC,"WPKFormID" ASC) REFERENCES "pears"."WPKLayout" ("WPKLayoutID","WPKFormID") ON DELETE CASCADE go ALTER TABLE "pears"."WPKLayoutViewStaff" ADD NOT NULL FOREIGN KEY "ViewK" ("WPKViewID" ASC,"WPKFormID" ASC) REFERENCES "pears"."WPKView" ("WPKViewID","WPKFormID") ON DELETE CASCADE go create trigger "TrackLViewStaffChange" after insert,delete,update order 1 on "pears"."WPKLayoutViewStaff" referencing new as "nlv" for each row begin call "WPKTrackChange"('F',"nlv"."WPKFormID") end go COMMENT TO PRESERVE FORMAT ON TRIGGER "pears"."WPKLayoutViewStaff"."TrackLViewStaffChange" IS {create trigger TrackLViewStaffChange after insert,delete,update order 1 on WPKLayoutViewStaff referencing new as nlv for each row begin call WPKTrackChange('F',nlv.WPKFormID) end } go </code> database/tables/pears_wpklayoutviewstaff.txt Last modified: 2026/08/07 19:24by 127.0.0.1