====== pears.PostCodeLocation ====== 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 ^ | **PostCodeLocationID** | bigint | NOT NULL | autoincrement | | | PostCode | char(20) | NOT NULL | | | | Easting | integer | NULL | | | | Northing | integer | NULL | | | | IQXPosition | ST_Point(SRID=999999) | NOT NULL | | | | WS84Position | ST_Point(SRID=4326) | NULL | | | ===== Primary Key ===== * PostCodeLocationID ===== Foreign Keys ===== * No outgoing foreign keys found. ===== Referenced By ===== * No incoming foreign keys found. ===== Indexes ===== ^ Name ^ Type ^ Columns ^ Detail ^ | PostCodeLocation_PostCode | Index | PostCode | | | PostCodeLocation_IQXPosition | Index | IQXPosition | | | PostCodeLocation_WS84Position | Index | WS84Position | | ===== Triggers ===== * No triggers found. ===== Original SQL ===== -- IQX database structure split by table -- Source: IQXDatabaseStructure - with comments.sql -- Table: "pears"."PostCodeLocation" -- Table comment: -- Statement count: 4 CREATE TABLE "pears"."PostCodeLocation" ( "PostCodeLocationID" bigint NOT NULL DEFAULT autoincrement ,"PostCode" char(20) NOT NULL ,"Easting" integer NULL ,"Northing" integer NULL ,"IQXPosition" ST_Point(SRID=999999) NULL COMPUTE (if("Easting" is not null and "Northing" is not null) then(new "st_point"("Easting","Northing",999999)) else null endif) ,"WS84Position" ST_Point(SRID=4326) NULL COMPUTE ("IQXPosition"."ST_Transform"(4326)) ,PRIMARY KEY ("PostCodeLocationID" ASC) ) go CREATE INDEX "PostCodeLocation_PostCode" ON "pears"."PostCodeLocation" ( "PostCode" ) go CREATE INDEX "PostCodeLocation_IQXPosition" ON "pears"."PostCodeLocation" ( "IQXPosition" ) go CREATE INDEX "PostCodeLocation_WS84Position" ON "pears"."PostCodeLocation" ( "WS84Position" ) go