changeset 5014:97dfb065a300 dami

merge
author Tom Gottfried <tom.gottfried@intevation.de>
date Tue, 19 Feb 2013 10:00:50 +0100
parents eecd1ebba128 (diff) a79f6a085ab6 (current diff)
children 808718c6de97
files
diffstat 3 files changed, 1 insertions(+), 34 deletions(-) [+]
line wrap: on
line diff
--- a/flys-backend/doc/schema/oracle-spatial.sql	Tue Feb 19 09:53:16 2013 +0100
+++ b/flys-backend/doc/schema/oracle-spatial.sql	Tue Feb 19 10:00:50 2013 +0100
@@ -59,33 +59,6 @@
 --CREATE INDEX CrossSectionTracks_spatial_idx ON cross_section_tracks(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=LINE');
 
 
--- TODO: TestMe. Fix Importer-Script. Fix oracle_spatial_idx.sql script.
--- Geodaesie/Linien/rohre-und-speeren
-CREATE SEQUENCE LINES_ID_SEQ;
-CREATE TABLE lines (
-    OGR_FID NUMBER(38),
-    GEOM MDSYS.SDO_GEOMETRY,
-    river_id NUMBER(38),
-    kind     VARCHAR2(16) NOT NULL,
-    z        NUMBER(38,12) DEFAULT 0,
-    name     VARCHAR(64),
-    path     VARCHAR(256),
-    ID NUMBER PRIMARY KEY NOT NULL
-);
-INSERT INTO USER_SDO_GEOM_METADATA VALUES ('lines', 'GEOM', MDSYS.SDO_DIM_ARRAY(MDSYS.SDO_DIM_ELEMENT('X',3282450,3912240,0.001),MDSYS.SDO_DIM_ELEMENT('Y',5248260,6100130,0.001),MDSYS.SDO_DIM_ELEMENT('Z',-100000,100000,0.002)), 31467);
-CREATE OR REPLACE TRIGGER lines_trigger BEFORE INSERT ON lines FOR each ROW
-    BEGIN
-        SELECT LINES_ID_SEQ.nextval INTO :new.id FROM dual;
-    END;
-/
--- NOTE: Should lines should be 3D.
--- TODO: Test index. 
---CREATE INDEX lines_idx ON lines(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=LINE');
--- 'kind':
--- 0: ROHR1
--- 1: DAMM
-
-
 -- Geodaesie/Bauwerke/Wehre.shp
 CREATE SEQUENCE BUILDINGS_ID_SEQ;
 CREATE TABLE buildings(
--- a/flys-backend/doc/schema/oracle-spatial_idx.sql	Tue Feb 19 09:53:16 2013 +0100
+++ b/flys-backend/doc/schema/oracle-spatial_idx.sql	Tue Feb 19 10:00:50 2013 +0100
@@ -6,4 +6,4 @@
 CREATE INDEX CrossSectionTracks_spatial_idx ON cross_section_tracks(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=LINE');
 CREATE INDEX hws_spatial_idx ON hws(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=LINE');
 CREATE INDEX floodplain_spatial_idx ON floodplain(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=POLYGON');
-CREATE INDEX lines_idx ON lines(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=LINE');
+
--- a/flys-backend/doc/schema/postgresql-spatial.sql	Tue Feb 19 09:53:16 2013 +0100
+++ b/flys-backend/doc/schema/postgresql-spatial.sql	Tue Feb 19 10:00:50 2013 +0100
@@ -41,23 +41,6 @@
 ALTER TABLE cross_section_tracks ALTER COLUMN id SET DEFAULT NEXTVAL('CROSS_SECTION_TRACKS_ID_SEQ');
 
 
--- Geodaesie/Linien/rohre-und-spreen
-CREATE SEQUENCE LINES_ID_SEQ;
-CREATE TABLE lines (
-    id       int PRIMARY KEY NOT NULL,
-    river_id int REFERENCES rivers(id) ON DELETE CASCADE,
-    kind     VARCHAR(16) NOT NULL,
-    z        FLOAT8 DEFAULT 0,
-    name     VARCHAR(64),
-    path     VARCHAR(256)
-);
-SELECT AddGeometryColumn('lines', 'geom', 31467, 'LINESTRING', 3);
-ALTER TABLE lines ALTER COLUMN id SET DEFAULT NEXTVAL('LINES_ID_SEQ');
--- 'kind':
--- 0: ROHR1
--- 1: DAMM
-
-
 -- Geodaesie/Bauwerke/Wehre.shp
 CREATE SEQUENCE BUILDINGS_ID_SEQ;
 CREATE TABLE buildings (

http://dive4elements.wald.intevation.org