changeset 3339:790c12c55abb

Backend: Added DB indices for fasten access to cross section points. flys-backend/trunk@4927 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Wed, 11 Jul 2012 10:37:03 +0000
parents e19a503e4150
children 509af52db23b
files flys-backend/ChangeLog flys-backend/doc/schema/oracle.sql flys-backend/doc/schema/postgresql.sql
diffstat 3 files changed, 16 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/flys-backend/ChangeLog	Wed Jul 11 08:09:32 2012 +0000
+++ b/flys-backend/ChangeLog	Wed Jul 11 10:37:03 2012 +0000
@@ -1,3 +1,8 @@
+2012-07-11	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
+
+	* doc/schema/postgresql.sql, doc/schema/oracle.sql:
+	  Added indices for fasten access to cross section points.
+
 2012-07-11	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
 
 	Partial fix for flys/issue697
--- a/flys-backend/doc/schema/oracle.sql	Wed Jul 11 08:09:32 2012 +0000
+++ b/flys-backend/doc/schema/oracle.sql	Wed Jul 11 10:37:03 2012 +0000
@@ -67,6 +67,11 @@
     PRIMARY KEY         (id)
 );
 
+-- Indices for faster access of the points
+CREATE INDEX cross_section_lines_km_idx
+    ON cross_section_lines(km);
+CREATE INDEX cross_section_points_line_idx
+    ON cross_section_points(cross_section_line_id);
 
 -- DISCHARGE_TABLE_VALUES
 CREATE SEQUENCE DISCHARGE_TABLE_VALUES_ID_SEQ;
--- a/flys-backend/doc/schema/postgresql.sql	Wed Jul 11 08:09:32 2012 +0000
+++ b/flys-backend/doc/schema/postgresql.sql	Wed Jul 11 10:37:03 2012 +0000
@@ -280,6 +280,12 @@
     description      VARCHAR(256)
 );
 
+-- Indices for faster access of the points
+CREATE INDEX cross_section_lines_km_idx
+    ON cross_section_lines(km);
+CREATE INDEX cross_section_points_line_idx
+    ON cross_section_points(cross_section_line_id);
+
 CREATE SEQUENCE CROSS_SECTION_LINES_ID_SEQ;
 
 CREATE TABLE cross_section_lines (

http://dive4elements.wald.intevation.org