[Mapbender-commits] r1114 - trunk/mapbender/resources/db/update

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Mon Feb 12 06:57:27 EST 2007


Author: astrid_emde
Date: 2007-02-12 06:57:26 -0500 (Mon, 12 Feb 2007)
New Revision: 1114

Modified:
   trunk/mapbender/resources/db/update/update_mysql_db.sql
Log:
new columns in table wfs_conf_elemet added and lots of primarykeys added

Modified: trunk/mapbender/resources/db/update/update_mysql_db.sql
===================================================================
--- trunk/mapbender/resources/db/update/update_mysql_db.sql	2007-02-12 11:57:05 UTC (rev 1113)
+++ trunk/mapbender/resources/db/update/update_mysql_db.sql	2007-02-12 11:57:26 UTC (rev 1114)
@@ -70,26 +70,6 @@
   PRIMARY KEY (md_topic_category_id)
 )TYPE = InnoDb;
 
-INSERT INTO md_topic_category VALUES (1, 'farming', 'Landwirtschaft');
-INSERT INTO md_topic_category VALUES (2, 'biota', 'Biotope');
-INSERT INTO md_topic_category VALUES (3, 'boundaries', 'Grenzen');
-INSERT INTO md_topic_category VALUES (4, 'climatologyMeteorologyAtmosphere', 'Wetterkunde');
-INSERT INTO md_topic_category VALUES (5, 'economy', 'Wirtschaft');
-INSERT INTO md_topic_category VALUES (6, 'elevation', 'Höhendaten');
-INSERT INTO md_topic_category VALUES (7, 'environment', 'Umwelt');
-INSERT INTO md_topic_category VALUES (8, 'geoscientificInformation', 'Geowissenschaft');
-INSERT INTO md_topic_category VALUES (9, 'health', 'Gesundheit');
-INSERT INTO md_topic_category VALUES (10, 'imageryBaseMapsEarthCover', 'Grundlagenkarten');
-INSERT INTO md_topic_category VALUES (11, 'intelligenceMilitary', 'militärische Aufklärung');
-INSERT INTO md_topic_category VALUES (12, 'inlandWaters', 'Binnengewässer');
-INSERT INTO md_topic_category VALUES (13, 'location', 'Ortsinformationen');
-INSERT INTO md_topic_category VALUES (14, 'oceans', 'Meereskunde');
-INSERT INTO md_topic_category VALUES (15, 'planningCadastre', 'Landnutzung/Planung/Kataster');
-INSERT INTO md_topic_category VALUES (16, 'society', 'Gesellschaft');
-INSERT INTO md_topic_category VALUES (17, 'structure', 'Bauwerke');
-INSERT INTO md_topic_category VALUES (18, 'transportation', 'Transportwesen');
-INSERT INTO md_topic_category VALUES (19, 'utilitiesCommunication', 'Infrastruktur');
-
 --
 -- new table: wms_md_topic_category
 --
@@ -98,6 +78,11 @@
   fkey_md_topic_category_id int(11) NOT NULL
 )TYPE = InnoDb;
 
+
+-- wms_owner has to be set
+-- Update wms set wms_owner =1;
+
+
 ALTER TABLE wms_md_topic_category
 ADD CONSTRAINT wms_md_topic_category_fkey_md_topic_category_id_fkey FOREIGN KEY (fkey_md_topic_category_id) 
 REFERENCES md_topic_category (md_topic_category_id) MATCH SIMPLE ON UPDATE CASCADE ON DELETE CASCADE;
@@ -107,4 +92,40 @@
 REFERENCES wms (wms_id) MATCH SIMPLE ON UPDATE CASCADE ON DELETE CASCADE;
 
 -- wms_owner has to be set
--- Update wms set wms_owner =1;
\ No newline at end of file
+-- Update wms set wms_owner =1;
+
+--
+-- new columns in table wfs_conf_element
+-- Selectbox (Text) for predefined values
+ALTER TABLE wfs_conf_element ADD f_box TEXT NULL ;
+ 
+-- editable
+ALTER TABLE wfs_conf_element ADD COLUMN f_edit int4;
+ 
+-- Pflichtfeld / mandatory 
+ALTER TABLE wfs_conf_element ADD COLUMN f_mandatory int4;
+ 
+--  
+-- add missing primary keys 
+--
+ALTER TABLE gui_layer ADD CONSTRAINT pk_gui_layer PRIMARY KEY (fkey_gui_id,fkey_layer_id);
+
+ALTER TABLE gui_wms ADD CONSTRAINT pk_gui_wms PRIMARY KEY (fkey_gui_id,fkey_wms_id);
+
+ALTER TABLE layer_keyword ADD CONSTRAINT pk_layer_keyword PRIMARY KEY (fkey_layer_id,fkey_keyword_id);
+
+ALTER TABLE mb_user_wmc ADD CONSTRAINT pk_user_wmc PRIMARY KEY (wmc_id);
+
+ALTER TABLE wfs_element ADD CONSTRAINT pk_wfs_element PRIMARY KEY (fkey_featuretype_id,element_id);
+
+ALTER TABLE wms_format ADD CONSTRAINT pk_wms_format PRIMARY KEY (fkey_wms_id,data_type,data_format);
+
+ALTER TABLE wms_md_topic_category ADD CONSTRAINT pk_md_topic_category PRIMARY KEY (fkey_wms_id,fkey_md_topic_category_id);
+
+ALTER TABLE wms_srs ADD CONSTRAINT pk_wms_srs PRIMARY KEY (fkey_wms_id,wms_srs);
+
+ALTER TABLE wfs_featuretype_namespace ADD CONSTRAINT pk_featuretype_namespace PRIMARY KEY  (fkey_wfs_id,fkey_featuretype_id,namespace);
+
+ALTER TABLE mb_monitor ADD CONSTRAINT pk_mb_monitor PRIMARY KEY  (upload_id,fkey_wms_id);
+
+ALTER TABLE mb_log ADD CONSTRAINT pk_mb_log PRIMARY KEY  (id); 



More information about the Mapbender_commits mailing list