[Mapbender-commits] r2696 - branches/2.5/resources/db/update
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Tue Jul 22 09:34:27 EDT 2008
Author: astrid_emde
Date: 2008-07-22 09:34:27 -0400 (Tue, 22 Jul 2008)
New Revision: 2696
Modified:
branches/2.5/resources/db/update/update_mysql_db.sql
Log:
prepare updatesql for mapbender 2.5
Modified: branches/2.5/resources/db/update/update_mysql_db.sql
===================================================================
--- branches/2.5/resources/db/update/update_mysql_db.sql 2008-07-22 13:32:55 UTC (rev 2695)
+++ branches/2.5/resources/db/update/update_mysql_db.sql 2008-07-22 13:34:27 UTC (rev 2696)
@@ -37,8 +37,70 @@
ALTER table wfs add wfs_timestamp int(11)
ALTER table wfs add country varchar(255);
+ALTER TABLE wfs ALTER COLUMN wfs_title SET NOT NULL;
+ALTER TABLE wfs ALTER COLUMN wfs_title SET DEFAULT ''::character varying;
+ALTER TABLE wfs ALTER COLUMN wfs_version SET NOT NULL;
+ALTER TABLE wfs ALTER COLUMN wfs_version SET DEFAULT ''::character varying;
+
+ALTER TABLE wfs ALTER COLUMN wfs_getcapabilities SET NOT NULL;
+ALTER TABLE wfs ALTER COLUMN wfs_getcapabilities SET DEFAULT ''::character varying;
+
+alter table wfs_featuretype add column featuretype_searchable integer default 1;
+alter table wfs_featuretype add column featuretype_abstract character varying(50);
+
+-- grant root access to default wfs
+UPDATE wfs SET wfs_owner = 1;
+
--
+-- new table gui_wfs_conf
+--
+CREATE TABLE gui_wfs_conf (
+ fkey_gui_id character varying(50) DEFAULT ''::character varying NOT NULL,
+ fkey_wfs_conf_id integer DEFAULT 0 NOT NULL
+);
+
+ALTER TABLE ONLY gui_wfs_conf
+ ADD CONSTRAINT pk_fkey_wfs_conf_id PRIMARY KEY (fkey_gui_id, fkey_wfs_conf_id);
+
+ALTER TABLE ONLY gui_wfs_conf
+ ADD CONSTRAINT gui_wfs_conf_ibfk_1 FOREIGN KEY (fkey_gui_id) REFERENCES gui(gui_id) ON UPDATE CASCADE ON DELETE CASCADE;
+
+ALTER TABLE ONLY gui_wfs_conf
+ ADD CONSTRAINT gui_wfs_conf_ibfk_2 FOREIGN KEY (fkey_wfs_conf_id) REFERENCES wfs_conf(wfs_conf_id) ON UPDATE CASCADE ON DELETE CASCADE;
+
+-- insert wfs confs into gui digitize
+INSERT INTO gui_wfs_conf (fkey_gui_id, fkey_wfs_conf_id) VALUES ('gui_digitize', 1);
+INSERT INTO gui_wfs_conf (fkey_gui_id, fkey_wfs_conf_id) VALUES ('gui_digitize', 3);
+INSERT INTO gui_wfs_conf (fkey_gui_id, fkey_wfs_conf_id) VALUES ('gui_digitize', 4);
+INSERT INTO gui_wfs_conf (fkey_gui_id, fkey_wfs_conf_id) VALUES ('gui_digitize', 2);
+
+
+
+--
+-- new table wfs_featuretype_keyword:
+--
+CREATE TABLE wfs_featuretype_keyword (
+ fkey_featuretype_id integer NOT NULL,
+ fkey_keyword_id integer NOT NULL
+);
+
+ALTER TABLE ONLY wfs_featuretype_keyword
+ ADD CONSTRAINT fkey_keyword_id_fkey_featuretype_id FOREIGN KEY (fkey_keyword_id) REFERENCES keyword(keyword_id) ON UPDATE CASCADE ON DELETE CASCADE;
+
+ALTER TABLE ONLY wfs_featuretype_keyword
+ ADD CONSTRAINT fkey_featuretype_id_fkey_keyword_id FOREIGN KEY (fkey_featuretype_id) REFERENCES wfs_featuretype(featuretype_id) ON UPDATE CASCADE ON DELETE CASCADE;
+
+--
+-- new table layer_load_count
+--
+CREATE TABLE layer_load_count (
+ fkey_layer_id int4,
+ load_count int8
+);
+
+
+--
-- table wfs_conf
--
ALTER TABLE wfs_conf add COLUMN wfs_conf_description text;
@@ -46,14 +108,15 @@
--
-- table wfs_conf_element: change in WFS configuration: access to geometries may now be restricted
--
-ALTER TABLE wfs_conf_element ADD COLUMN f_auth_varname VARCHAR(50) NULL;
+ALTER TABLE wfs_conf_element ADD COLUMN f_auth_varname VARCHAR(50);
ALTER TABLE wfs_conf_element ADD COLUMN f_show_detail int4;
-ALTER TABLE wfs_conf_element ADD COLUMN f_operator VARCHAR(50) NULL;
+ALTER TABLE wfs_conf_element ADD COLUMN f_operator VARCHAR(50);
--
-- table gui_element: new column for translation
--
ALTER TABLE gui_element ADD COLUMN e_title VARCHAR(255) NULL;
+INSERT INTO gui_element(fkey_gui_id, e_id, e_pos, e_public, e_comment, e_element, e_src, e_attributes, e_left, e_top, e_width, e_height, e_z_index, e_more_styles, e_content, e_closetag, e_js_file, e_mb_mod, e_target, e_requires, e_url) VALUES('admin1','WFS',2,1,'edit wfs settings','a','','href = "../javascripts/mod_wfs_client.html" target="AdminFrame"',10,1005,250,20,NULL ,'font-family: Arial, Helvetica, sans-serif; font-size : 12px; text-decoration : none; color: #808080;','EDIT WFS','a','','','','AdminFrame','');
--
More information about the Mapbender_commits
mailing list