GLE-Layer-Reichsbodenschätzung: Unterschied zwischen den Versionen

Aus kvwmap
Wechseln zu: Navigation, Suche
(Die Seite wurde neu angelegt: „ == Layer Bodenschätzung für die klassifizierte Darstellung der Schätzungsflächen == SET @group_id = 1; SET @connection = 'user=xxxx password=xxxx dbnam…“)
 
 
Zeile 1: Zeile 1:
 +
== Layer Klassifizierte Bodenwertzahlen der Schätzungsflächen ==
  
== Layer Bodenschätzung für die klassifizierte Darstellung der Schätzungsflächen ==
+
Je ein Layer für Acker- und Grünland, außerdem je ein Layer für Acker-Grünland-Wechselland sowie Grünland-Acker-Wechselland.
  
 
  SET @group_id = 1;
 
  SET @group_id = 1;
  SET @connection = 'user=xxxx password=xxxx dbname=kvwmapsp';  
+
  SET @connection = 'user=xxxx password=xxxx dbname=kvwmapsp';
 
   
 
   
  INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('ALKIS_Bodenschätzung','Bodenschätzung','2',@group_id,'SELECT * FROM ax_bodenschaetzung WHERE CASE WHEN \'$hist_timestamp\' = \'\' THEN endet IS NULL ELSE beginnt <= \'$hist_timestamp\' AND (\'$hist_timestamp\' <= endet or endet IS NULL) END','ax_bodenschaetzung','wkb_geometry from (SELECT a.oid, c.kurz||d.kurz AS label, b.kurz, a.wkb_geometry FROM alkis.ax_bodenschaetzung AS a INNER JOIN alkis.ax_bodenschaetzung_kulturart AS b ON a.kulturart=b.wert INNER JOIN alkis.ax_bodenschaetzung_bodenart AS c ON a.bodenart=c.wert INNER JOIN alkis.ax_bodenschaetzung_zustandsstufe AS d ON a.zustandsstufeoderbodenstufe = d.wert WHERE (CASE WHEN \'$hist_timestamp\' = \'\' THEN a.endet IS NULL ELSE a.beginnt <= \'$hist_timestamp\' AND (\'$hist_timestamp\' <= a.endet or a.endet IS NULL)
+
  INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen (A)','','2',@group_id,'','lkvr_schaetzungsflaechen','geometrie from (SELECT id as oid, ackerzahlodergruenlandzahl, kulturart_kurz, geometrie FROM alkis.lkvr_schaetzungsflaechen WHERE kulturart_kurz = \'A\') as foo using unique oid using srid=25833','alkis','','','','','',NULL,NULL,'',@connection,'','6','ackerzahlodergruenlandzahl','ackerzahlodergruenlandzahl','3','pixels','25833','','0','100','28808','49','1000001','','EPSG:25833','','1.1.0','image/png','60','','','','','1','0','','Farbige Darstellung der BWZ für Acker','Breede','','0');
  END)) as foo using unique oid using srid=25833','alkis','','','','','label','5001','49','',@connection,'','6','','oid','3','pixels','25833','','1','50','94000','50','5000','','EPSG:25833','','1.1.0','image/png','60','','','','','1','0','','Reichsbodenschätzung aus ALKIS','Fachdienst Kataster und Vermessung','','0');
+
  SET @last_layer_id50303599=LAST_INSERT_ID();
  SET @last_layer_id50303347=LAST_INSERT_ID();
+
  INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 1 AND [ackerzahlodergruenlandzahl] < 21)','1','');
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'ackerzahlodergruenlandzahl','ackerzahlodergruenlandzahl','ax_bodenschaetzung','ax_bodenschaetzung','int4','','','1','32',NULL,'','Text','','Ackerzahl oder Grünlandzahl','','','','','','',NULL,NULL,'15','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'advstandardmodell','advstandardmodell','ax_bodenschaetzung','ax_bodenschaetzung','_varchar','','','1',NULL,NULL,'','Text','','ADV Standardmodell','','','','','','',NULL,NULL,'5','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'anlass','anlass','ax_bodenschaetzung','ax_bodenschaetzung','varchar','','','1',NULL,NULL,'','Text','','Anlass','','','','','','',NULL,NULL,'7','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'art','art','ax_bodenschaetzung','ax_bodenschaetzung','varchar','','','1',NULL,NULL,'','Text','','Art','','','','','','',NULL,NULL,'8','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'beginnt','beginnt','ax_bodenschaetzung','ax_bodenschaetzung','bpchar','','UNIQUE','1','20',NULL,'','Text','','','','','','','','',NULL,NULL,'3','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'bodenart','bodenart','ax_bodenschaetzung','ax_bodenschaetzung','int4','','','1','32',NULL,'','Text','','Bodenart','','','','','','',NULL,NULL,'11','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'bodenzahlodergruenlandgrundzahl','bodenzahlodergruenlandgrundzahl','ax_bodenschaetzung','ax_bodenschaetzung','int4','','','1','32',NULL,'','Text','','Bodenzahl oder Grünlandgrundzahl','','','','','','',NULL,NULL,'14','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'endet','endet','ax_bodenschaetzung','ax_bodenschaetzung','bpchar','','','1','20',NULL,'','Text','','','','','','','','',NULL,NULL,'4','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'entstehungsartoderklimastufewasserverhaeltnisse','entstehungsartoderklimastufewasserverhaeltnisse','ax_bodenschaetzung','ax_bodenschaetzung','_int4','','','1',NULL,NULL,'','Text','','Entstehungsart/Klimastufe Wasserverhältnisse','','','','','','',NULL,NULL,'13','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'gml_id','gml_id','ax_bodenschaetzung','ax_bodenschaetzung','varchar','','UNIQUE','0','16',NULL,'','Text','','','','','','','','',NULL,NULL,'1','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'identifier','identifier','ax_bodenschaetzung','ax_bodenschaetzung','varchar','','','1',NULL,NULL,'','Text','','','','','','','','',NULL,NULL,'2','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'jahreszahl','jahreszahl','ax_bodenschaetzung','ax_bodenschaetzung','int4','','','1','32',NULL,'','Text','','Jahreszahl','','','','','','',NULL,NULL,'17','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'kulturart','kulturart','ax_bodenschaetzung','ax_bodenschaetzung','int4','','','1','32',NULL,'','Text','','Kulturart','','','','','','',NULL,NULL,'10','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'name','name','ax_bodenschaetzung','ax_bodenschaetzung','varchar','','','1',NULL,NULL,'','Text','','Name','','','','','','',NULL,NULL,'9','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'ogc_fid','ogc_fid','ax_bodenschaetzung','ax_bodenschaetzung','int4','','PRIMARY KEY','1','32',NULL,'','Text','','','','','','','','',NULL,NULL,'0','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'sonstigeangaben','sonstigeangaben','ax_bodenschaetzung','ax_bodenschaetzung','_int4','','','1',NULL,NULL,'','Text','','sonstige Angaben','','','','','','',NULL,NULL,'16','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'sonstigesmodell','sonstigesmodell','ax_bodenschaetzung','ax_bodenschaetzung','_varchar','','','1',NULL,NULL,'','Text','','sonstiges Modell','','','','','','',NULL,NULL,'6','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'wkb_geometry','wkb_geometry','ax_bodenschaetzung','ax_bodenschaetzung','geometry','POLYGON','','1',NULL,NULL,'','Geometrie','','','','','','','','',NULL,NULL,'18','0','0');
+
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`decimal_length`,`default`,`form_element_type`,`options`,`alias`,`alias_low-german`,`alias_english`,`alias_polish`,`alias_vietnamese`,`tooltip`,`group`,`raster_visibility`,`mandatory`,`order`,`privileg`,`query_tooltip`) VALUES(@last_layer_id50303347,'zustandsstufeoderbodenstufe','zustandsstufeoderbodenstufe','ax_bodenschaetzung','ax_bodenschaetzung','int4','','','1','32',NULL,'','Text','','Zustands-/Bodenstufe','','','','','','',NULL,NULL,'12','0','0');
+
  INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Ackerland',@last_layer_id50303347,'(\'[kurz]\' = \'A\')','1','');
+
 
  SET @last_class_id=LAST_INSERT_ID();
 
  SET @last_class_id=LAST_INSERT_ID();
  INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','3','205 116 40','','-1 -1 -1',NULL,NULL,'','',NULL,NULL,NULL,NULL,'');
+
  INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','255 250 179','','255 250 179',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
SET @last_style_id=LAST_INSERT_ID();
+
  SET @last_style_id=LAST_INSERT_ID();
 
  INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 
  INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','-1 -1 -1','','0 98 3',NULL,NULL,'','',NULL,'3','4','5','');
+
  INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 21 AND [ackerzahlodergruenlandzahl] < 31)','1','');
SET @last_style_id=LAST_INSERT_ID();
+
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 1);
+
INSERT INTO labels (`font`,`type`,`color`,`outlinecolor`,`shadowcolor`,`shadowsizex`,`shadowsizey`,`backgroundcolor`,`backgroundshadowcolor`,`backgroundshadowsizex`,`backgroundshadowsizey`,`size`,`minsize`,`maxsize`,`position`,`offsetx`,`offsety`,`angle`,`autoangle`,`buffer`,`antialias`,`minfeaturesize`,`maxfeaturesize`,`partials`,`wrap`,`the_force`) VALUES('verdana',NULL,'89 39 0','255 255 255','',NULL,NULL,'','',NULL,NULL,'8','6','10',NULL,NULL,NULL,NULL,NULL,NULL,'1',NULL,NULL,'1','126','1');
+
SET @last_label_id=LAST_INSERT_ID();
+
INSERT INTO u_labels2classes (label_id, class_id) VALUES (@last_label_id, @last_class_id);
+
  INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Acker-Grünland',@last_layer_id50303347,'(\'[kurz]\' = \'AGr\')','2','');
+
 
  SET @last_class_id=LAST_INSERT_ID();
 
  SET @last_class_id=LAST_INSERT_ID();
  INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','3','231 168 0','','-1 -1 -1',NULL,NULL,'','',NULL,NULL,NULL,NULL,'');
+
  INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','224 208 143','','224 208 143',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
SET @last_style_id=LAST_INSERT_ID();
+
  SET @last_style_id=LAST_INSERT_ID();
 
  INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 
  INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','-1 -1 -1','','0 98 3',NULL,NULL,'','',NULL,'3','4','5','');
+
  INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 31 AND [ackerzahlodergruenlandzahl] < 41)','1','');
SET @last_style_id=LAST_INSERT_ID();
+
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 1);
+
INSERT INTO labels (`font`,`type`,`color`,`outlinecolor`,`shadowcolor`,`shadowsizex`,`shadowsizey`,`backgroundcolor`,`backgroundshadowcolor`,`backgroundshadowsizex`,`backgroundshadowsizey`,`size`,`minsize`,`maxsize`,`position`,`offsetx`,`offsety`,`angle`,`autoangle`,`buffer`,`antialias`,`minfeaturesize`,`maxfeaturesize`,`partials`,`wrap`,`the_force`) VALUES('verdana',NULL,'89 39 0','255 255 255','',NULL,NULL,'','',NULL,NULL,'8','6','10',NULL,NULL,NULL,NULL,NULL,NULL,'1',NULL,NULL,'1','126','1');
+
SET @last_label_id=LAST_INSERT_ID();
+
INSERT INTO u_labels2classes (label_id, class_id) VALUES (@last_label_id, @last_class_id);
+
  INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Grünland',@last_layer_id50303347,'(\'[kurz]\' = \'Gr\')','3','');
+
 
  SET @last_class_id=LAST_INSERT_ID();
 
  SET @last_class_id=LAST_INSERT_ID();
  INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','3','143 249 44','','-1 -1 -1',NULL,NULL,'','',NULL,NULL,NULL,NULL,'');
+
  INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','193 166 107','','193 166 107',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
SET @last_style_id=LAST_INSERT_ID();
+
  SET @last_style_id=LAST_INSERT_ID();
 
  INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 
  INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','-1 -1 -1','','0 98 3',NULL,NULL,'','',NULL,'3','4','5','');
+
  INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 41 AND [ackerzahlodergruenlandzahl] < 51)','1','');
SET @last_style_id=LAST_INSERT_ID();
+
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 1);
+
INSERT INTO labels (`font`,`type`,`color`,`outlinecolor`,`shadowcolor`,`shadowsizex`,`shadowsizey`,`backgroundcolor`,`backgroundshadowcolor`,`backgroundshadowsizex`,`backgroundshadowsizey`,`size`,`minsize`,`maxsize`,`position`,`offsetx`,`offsety`,`angle`,`autoangle`,`buffer`,`antialias`,`minfeaturesize`,`maxfeaturesize`,`partials`,`wrap`,`the_force`) VALUES('verdana',NULL,'0 59 31','255 255 255','',NULL,NULL,'','',NULL,NULL,'8','6','10',NULL,NULL,NULL,NULL,NULL,NULL,'1',NULL,NULL,'1','126','1');
+
SET @last_label_id=LAST_INSERT_ID();
+
INSERT INTO u_labels2classes (label_id, class_id) VALUES (@last_label_id, @last_class_id);
+
  INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Grünland-Acker',@last_layer_id50303347,'(\'[kurz]\' = \'GrA\')','4','');
+
 
  SET @last_class_id=LAST_INSERT_ID();
 
  SET @last_class_id=LAST_INSERT_ID();
  INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','3','22 154 0','','-1 -1 -1',NULL,NULL,'','',NULL,NULL,NULL,NULL,'');
+
  INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','162 124 72','','162 124 72',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
  SET @last_style_id=LAST_INSERT_ID();
+
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 51 AND [ackerzahlodergruenlandzahl] < 61)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','131 82 36','','131 82 36',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-75',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 61 AND [ackerzahlodergruenlandzahl] < 75)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','101 40 1','','101 40 1',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
 +
INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen (AGr)','','2',@group_id,'','lkvr_schaetzungsflaechen','geometrie from (SELECT id as oid, ackerzahlodergruenlandzahl, kulturart_kurz, geometrie FROM alkis.lkvr_schaetzungsflaechen WHERE kulturart_kurz = \'AGr\') as foo using unique oid using srid=25833','alkis','','','','','',NULL,NULL,'',@connection,'','6','ackerzahlodergruenlandzahl','ackerzahlodergruenlandzahl','3','pixels','25833','','0','100','28806','49','1000001','','EPSG:25833','','1.1.0','image/png','60','','','','','1','0','','Farbige Darstellung der BWZ für Acker-/Grünland','Breede','','0');
 +
SET @last_layer_id50303601=LAST_INSERT_ID();
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 1 AND [ackerzahlodergruenlandzahl] < 21)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','204 255 252','','204 255 252',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 21 AND [ackerzahlodergruenlandzahl] < 31)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','170 226 222','','170 226 222',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
  INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 31 AND [ackerzahlodergruenlandzahl] < 41)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','137 197 193','','137 197 193',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 41 AND [ackerzahlodergruenlandzahl] < 51)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','103 168 164','','103 168 164',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 51 AND [ackerzahlodergruenlandzahl] < 61)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','70 139 135','','70 139 135',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 61 AND [ackerzahlodergruenlandzahl] < 71)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','37 111 106','','37 111 106',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
 +
INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen (Gr)','','2',@group_id,'','lkvr_schaetzungsflaechen','geometrie from (SELECT id as oid, ackerzahlodergruenlandzahl, kulturart_kurz, geometrie FROM alkis.lkvr_schaetzungsflaechen WHERE kulturart_kurz = \'Gr\') as foo using unique oid using srid=25833','alkis','','','','','',NULL,NULL,'',@connection,'','6','ackerzahlodergruenlandzahl','ackerzahlodergruenlandzahl','3','pixels','25833','','0','100','28807','49','1000001','','EPSG:25833','','1.1.0','image/png','60','','','','','1','0','','Farbige Darstellung der BWZ für Grünland','Breede','','0');
 +
SET @last_layer_id50303600=LAST_INSERT_ID();
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 1 AND [ackerzahlodergruenlandzahl] < 21)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','237 255 179','','237 255 179',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 21 AND [ackerzahlodergruenlandzahl] < 31)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','193 225 143','','193 225 143',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 31 AND [ackerzahlodergruenlandzahl] < 41)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','149 195 108','','149 195 108',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 41 AND [ackerzahlodergruenlandzahl] < 51)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','105 165 72','','105 165 72',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 51 AND [ackerzahlodergruenlandzahl] < 61)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','61 135 37','','61 135 37',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 61 AND [ackerzahlodergruenlandzahl] < 71)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','18 105 2','','18 105 2',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
 +
INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen (GrA)','','2',@group_id,'','lkvr_schaetzungsflaechen','geometrie from (SELECT id as oid, ackerzahlodergruenlandzahl, kulturart_kurz, geometrie FROM alkis.lkvr_schaetzungsflaechen WHERE kulturart_kurz = \'GrA\') as foo using unique oid using srid=25833','alkis','','','','','',NULL,NULL,'',@connection,'','6','ackerzahlodergruenlandzahl','ackerzahlodergruenlandzahl','3','pixels','25833','','0','100','28805','49','1000001','','EPSG:25833','','1.1.0','image/png','60','','','','','1','0','','Farbige Darstellung der BWZ für Grün-/Ackerland','Breede','','0');
 +
SET @last_layer_id50303602=LAST_INSERT_ID();
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 1 AND [ackerzahlodergruenlandzahl] < 21)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','255 204 241','','255 204 241',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 21 AND [ackerzahlodergruenlandzahl] < 31)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','222 167 217','','222 167 217',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 31 AND [ackerzahlodergruenlandzahl] < 41)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','189 130 193','','189 130 193',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 41 AND [ackerzahlodergruenlandzahl] < 51)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','157 94 169','','157 94 169',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 51 AND [ackerzahlodergruenlandzahl] < 61)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','124 57 145','','124 57 145',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 61 AND [ackerzahlodergruenlandzahl] < 71)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','92 21 121','','92 21 121',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
 +
UPDATE layer_attributes SET options = REPLACE(options, '50303599', @last_layer_id50303599) WHERE layer_id IN(@last_layer_id50303599, @last_layer_id50303601, @last_layer_id50303600, @last_layer_id50303602) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
 +
UPDATE layer_attributes SET options = REPLACE(options, '50303601', @last_layer_id50303601) WHERE layer_id IN(@last_layer_id50303599, @last_layer_id50303601, @last_layer_id50303600, @last_layer_id50303602) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
 +
UPDATE layer_attributes SET options = REPLACE(options, '50303600', @last_layer_id50303600) WHERE layer_id IN(@last_layer_id50303599, @last_layer_id50303601, @last_layer_id50303600, @last_layer_id50303602) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
 +
UPDATE layer_attributes SET options = REPLACE(options, '50303602', @last_layer_id50303602) WHERE layer_id IN(@last_layer_id50303599, @last_layer_id50303601, @last_layer_id50303600, @last_layer_id50303602) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
 +
 
 +
== Layer Klassifizierte Bodenwertzahlen pro Flurstück ==
 +
 
 +
Je ein Layer für Acker- und Grünland, außerdem je ein Layer für Acker-Grünland-Wechselland sowie Grünland-Acker-Wechselland.
 +
 
 +
SET @group_id = 1;
 +
SET @connection = 'user=xxxx password=xxxx dbname=kvwmapsp';
 +
 +
INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen je Flurstück (A)','','2',@group_id,'','lkvr_schaetzungsflaechen_flurstueck','wkb_geometry from (SELECT s.fsgml_id as oid, s.a_bwz_gesamt, f.wkb_geometry FROM alkis.lkvr_schaetzungsflaechen_flurstueck s, alkis.ax_flurstueck f WHERE s.fsgml_id = f.gml_id) as foo using unique oid using srid=25833','alkis','','','','','',NULL,NULL,'',@connection,'','6','a_bwz_gesamt','a_bwz_gesamt','3','pixels','25833','','0','100','28804','49','1000001','','EPSG:25833','','1.1.0','image/png','60','','','','','1','0','','Farbige Darstellung der BWZ für Acker','Breede','','0');
 +
SET @last_layer_id50303590=LAST_INSERT_ID();
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303590,'([a_bwz_gesamt] >= 1 AND [a_bwz_gesamt] < 21)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','255 250 179','','255 250 179',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303590,'([a_bwz_gesamt] >= 21 AND [a_bwz_gesamt] < 31)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','224 208 143','','224 208 143',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303590,'([a_bwz_gesamt] >= 31 AND [a_bwz_gesamt] < 41)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','193 166 107','','193 166 107',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303590,'([a_bwz_gesamt] >= 41 AND [a_bwz_gesamt] < 51)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','162 124 72','','162 124 72',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303590,'([a_bwz_gesamt] >= 51 AND [a_bwz_gesamt] < 61)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','131 82 36','','131 82 36',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303590,'([a_bwz_gesamt] >= 61 AND [a_bwz_gesamt] < 71)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','101 40 1','','101 40 1',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
 +
INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen je Flurstück (AGr)','','2',@group_id,'','lkvr_schaetzungsflaechen_flurstueck','wkb_geometry from (SELECT s.fsgml_id as oid, s.agr_bwz_gesamt, f.wkb_geometry FROM alkis.lkvr_schaetzungsflaechen_flurstueck s, alkis.ax_flurstueck f WHERE s.fsgml_id = f.gml_id) as foo using unique oid using srid=25833','alkis','','','','','',NULL,NULL,'',@connection,'','6','agr_bwz_gesamt','agr_bwz_gesamt','3','pixels','25833','','0','100','28802','49','1000001','','EPSG:25833','','1.1.0','image/png','60','','','','','1','0','','Farbige Darstellung der BWZ für Acker-/Grünland','Breede','','0');
 +
SET @last_layer_id50303594=LAST_INSERT_ID();
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303594,'([agr_bwz_gesamt] >= 1 AND [agr_bwz_gesamt] < 21)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','204 255 252','','204 255 252',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303594,'([agr_bwz_gesamt] >= 21 AND [agr_bwz_gesamt] < 31)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','170 226 222','','170 226 222',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303594,'([agr_bwz_gesamt] >= 31 AND [agr_bwz_gesamt] < 41)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','137 197 193','','137 197 193',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303594,'([agr_bwz_gesamt] >= 41 AND [agr_bwz_gesamt] < 51)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','103 168 164','','103 168 164',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303594,'([agr_bwz_gesamt] >= 51 AND [agr_bwz_gesamt] < 61)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','70 139 135','','70 139 135',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303594,'([agr_bwz_gesamt] >= 61 AND [agr_bwz_gesamt] < 71)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','37 111 106','','37 111 106',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
 +
INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen je Flurstück (Gr)','','2',@group_id,'','lkvr_schaetzungsflaechen_flurstueck','wkb_geometry from (SELECT s.fsgml_id as oid, s.gr_bwz_gesamt, f.wkb_geometry FROM alkis.lkvr_schaetzungsflaechen_flurstueck s, alkis.ax_flurstueck f WHERE s.fsgml_id = f.gml_id) as foo using unique oid using srid=25833','alkis','','','','','',NULL,NULL,'',@connection,'','6','gr_bwz_gesamt','gr_bwz_gesamt','3','pixels','25833','','0','100','28803','49','1000001','','EPSG:25833','','1.1.0','image/png','60','','','','','1','0','','Farbige Darstellung der BWZ für Grünland','Breede','','0');
 +
SET @last_layer_id50303592=LAST_INSERT_ID();
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303592,'([gr_bwz_gesamt] >= 1 AND [gr_bwz_gesamt] < 21)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','237 255 179','','237 255 179',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303592,'([gr_bwz_gesamt] >= 21 AND [gr_bwz_gesamt] < 31)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','193 225 143','','193 225 143',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303592,'([gr_bwz_gesamt] >= 31 AND [gr_bwz_gesamt] < 41)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','149 195 108','','149 195 108',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303592,'([gr_bwz_gesamt] >= 41 AND [gr_bwz_gesamt] < 51)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','105 165 72','','105 165 72',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303592,'([gr_bwz_gesamt] >= 51 AND [gr_bwz_gesamt] < 61)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','61 135 37','','61 135 37',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303592,'([gr_bwz_gesamt] >= 61 AND [gr_bwz_gesamt] < 71)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','18 105 2','','18 105 2',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
 +
INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen je Flurstück (GrA)','','2',@group_id,'','lkvr_schaetzungsflaechen_flurstueck','wkb_geometry from (SELECT s.fsgml_id as oid, s.gra_bwz_gesamt, f.wkb_geometry FROM alkis.lkvr_schaetzungsflaechen_flurstueck s, alkis.ax_flurstueck f WHERE s.fsgml_id = f.gml_id) as foo using unique oid using srid=25833','alkis','','','','','',NULL,NULL,'',@connection,'','6','gra_bwz_gesamt','gra_bwz_gesamt','3','pixels','25833','','0','100','28801','49','1000001','','EPSG:25833','','1.1.0','image/png','60','','','','','1','0','','Farbige Darstellung der BWZ für Grün-/Ackerland','Breede','','0');
 +
SET @last_layer_id50303596=LAST_INSERT_ID();
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303596,'([gra_bwz_gesamt] >= 1 AND [gra_bwz_gesamt] < 21)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','255 204 241','','255 204 241',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303596,'([gra_bwz_gesamt] >= 21 AND [gra_bwz_gesamt] < 31)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','222 167 217','','222 167 217',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303596,'([gra_bwz_gesamt] >= 31 AND [gra_bwz_gesamt] < 41)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','189 130 193','','189 130 193',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303596,'([gra_bwz_gesamt] >= 41 AND [gra_bwz_gesamt] < 51)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','157 94 169','','157 94 169',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303596,'([gra_bwz_gesamt] >= 51 AND [gra_bwz_gesamt] < 61)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','124 57 145','','124 57 145',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 +
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 +
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303596,'([gra_bwz_gesamt] >= 61 AND [gra_bwz_gesamt] < 71)','1','');
 +
SET @last_class_id=LAST_INSERT_ID();
 +
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','92 21 121','','92 21 121',NULL,'1','360','',NULL,NULL,NULL,NULL,'');
 +
  SET @last_style_id=LAST_INSERT_ID();
 
  INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
 
  INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'','','-1 -1 -1','','0 98 3',NULL,NULL,'','',NULL,'3','4','5','');
 
SET @last_style_id=LAST_INSERT_ID();
 
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 1);
 
INSERT INTO labels (`font`,`type`,`color`,`outlinecolor`,`shadowcolor`,`shadowsizex`,`shadowsizey`,`backgroundcolor`,`backgroundshadowcolor`,`backgroundshadowsizex`,`backgroundshadowsizey`,`size`,`minsize`,`maxsize`,`position`,`offsetx`,`offsety`,`angle`,`autoangle`,`buffer`,`antialias`,`minfeaturesize`,`maxfeaturesize`,`partials`,`wrap`,`the_force`) VALUES('verdana',NULL,'0 59 31','255 255 255','',NULL,NULL,'','',NULL,NULL,'8','6','10',NULL,NULL,NULL,NULL,NULL,NULL,'1',NULL,NULL,'1','126','1');
 
SET @last_label_id=LAST_INSERT_ID();
 
INSERT INTO u_labels2classes (label_id, class_id) VALUES (@last_label_id, @last_class_id);
 
 
   
 
   
  UPDATE layer_attributes SET options = REPLACE(options, '50303347', @last_layer_id50303347) WHERE layer_id IN(@last_layer_id50303347) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
+
  UPDATE layer_attributes SET options = REPLACE(options, '50303590', @last_layer_id50303590) WHERE layer_id IN(@last_layer_id50303590, @last_layer_id50303594, @last_layer_id50303592, @last_layer_id50303596) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
 +
UPDATE layer_attributes SET options = REPLACE(options, '50303594', @last_layer_id50303594) WHERE layer_id IN(@last_layer_id50303590, @last_layer_id50303594, @last_layer_id50303592, @last_layer_id50303596) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
 +
UPDATE layer_attributes SET options = REPLACE(options, '50303592', @last_layer_id50303592) WHERE layer_id IN(@last_layer_id50303590, @last_layer_id50303594, @last_layer_id50303592, @last_layer_id50303596) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
 +
UPDATE layer_attributes SET options = REPLACE(options, '50303596', @last_layer_id50303596) WHERE layer_id IN(@last_layer_id50303590, @last_layer_id50303594, @last_layer_id50303592, @last_layer_id50303596) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');

Aktuelle Version vom 3. August 2015, 15:32 Uhr

Layer Klassifizierte Bodenwertzahlen der Schätzungsflächen

Je ein Layer für Acker- und Grünland, außerdem je ein Layer für Acker-Grünland-Wechselland sowie Grünland-Acker-Wechselland.

SET @group_id = 1;
SET @connection = 'user=xxxx password=xxxx dbname=kvwmapsp';

INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen (A)',,'2',@group_id,,'lkvr_schaetzungsflaechen','geometrie from (SELECT id as oid, ackerzahlodergruenlandzahl, kulturart_kurz, geometrie FROM alkis.lkvr_schaetzungsflaechen WHERE kulturart_kurz = \'A\') as foo using unique oid using srid=25833','alkis',,,,,,NULL,NULL,,@connection,,'6','ackerzahlodergruenlandzahl','ackerzahlodergruenlandzahl','3','pixels','25833',,'0','100','28808','49','1000001',,'EPSG:25833',,'1.1.0','image/png','60',,,,,'1','0',,'Farbige Darstellung der BWZ für Acker','Breede',,'0');
SET @last_layer_id50303599=LAST_INSERT_ID();
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 1 AND [ackerzahlodergruenlandzahl] < 21)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'255 250 179',,'255 250 179',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 21 AND [ackerzahlodergruenlandzahl] < 31)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'224 208 143',,'224 208 143',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 31 AND [ackerzahlodergruenlandzahl] < 41)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'193 166 107',,'193 166 107',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 41 AND [ackerzahlodergruenlandzahl] < 51)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'162 124 72',,'162 124 72',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 51 AND [ackerzahlodergruenlandzahl] < 61)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'131 82 36',,'131 82 36',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-75',@last_layer_id50303599,'([ackerzahlodergruenlandzahl] >= 61 AND [ackerzahlodergruenlandzahl] < 75)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'101 40 1',,'101 40 1',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);

INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen (AGr)',,'2',@group_id,,'lkvr_schaetzungsflaechen','geometrie from (SELECT id as oid, ackerzahlodergruenlandzahl, kulturart_kurz, geometrie FROM alkis.lkvr_schaetzungsflaechen WHERE kulturart_kurz = \'AGr\') as foo using unique oid using srid=25833','alkis',,,,,,NULL,NULL,,@connection,,'6','ackerzahlodergruenlandzahl','ackerzahlodergruenlandzahl','3','pixels','25833',,'0','100','28806','49','1000001',,'EPSG:25833',,'1.1.0','image/png','60',,,,,'1','0',,'Farbige Darstellung der BWZ für Acker-/Grünland','Breede',,'0');
SET @last_layer_id50303601=LAST_INSERT_ID();
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 1 AND [ackerzahlodergruenlandzahl] < 21)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'204 255 252',,'204 255 252',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 21 AND [ackerzahlodergruenlandzahl] < 31)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'170 226 222',,'170 226 222',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 31 AND [ackerzahlodergruenlandzahl] < 41)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'137 197 193',,'137 197 193',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 41 AND [ackerzahlodergruenlandzahl] < 51)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'103 168 164',,'103 168 164',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 51 AND [ackerzahlodergruenlandzahl] < 61)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'70 139 135',,'70 139 135',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303601,'([ackerzahlodergruenlandzahl] >= 61 AND [ackerzahlodergruenlandzahl] < 71)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'37 111 106',,'37 111 106',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);

INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen (Gr)',,'2',@group_id,,'lkvr_schaetzungsflaechen','geometrie from (SELECT id as oid, ackerzahlodergruenlandzahl, kulturart_kurz, geometrie FROM alkis.lkvr_schaetzungsflaechen WHERE kulturart_kurz = \'Gr\') as foo using unique oid using srid=25833','alkis',,,,,,NULL,NULL,,@connection,,'6','ackerzahlodergruenlandzahl','ackerzahlodergruenlandzahl','3','pixels','25833',,'0','100','28807','49','1000001',,'EPSG:25833',,'1.1.0','image/png','60',,,,,'1','0',,'Farbige Darstellung der BWZ für Grünland','Breede',,'0');
SET @last_layer_id50303600=LAST_INSERT_ID();
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 1 AND [ackerzahlodergruenlandzahl] < 21)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'237 255 179',,'237 255 179',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 21 AND [ackerzahlodergruenlandzahl] < 31)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'193 225 143',,'193 225 143',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 31 AND [ackerzahlodergruenlandzahl] < 41)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'149 195 108',,'149 195 108',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 41 AND [ackerzahlodergruenlandzahl] < 51)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'105 165 72',,'105 165 72',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 51 AND [ackerzahlodergruenlandzahl] < 61)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'61 135 37',,'61 135 37',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303600,'([ackerzahlodergruenlandzahl] >= 61 AND [ackerzahlodergruenlandzahl] < 71)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'18 105 2',,'18 105 2',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);

INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen (GrA)',,'2',@group_id,,'lkvr_schaetzungsflaechen','geometrie from (SELECT id as oid, ackerzahlodergruenlandzahl, kulturart_kurz, geometrie FROM alkis.lkvr_schaetzungsflaechen WHERE kulturart_kurz = \'GrA\') as foo using unique oid using srid=25833','alkis',,,,,,NULL,NULL,,@connection,,'6','ackerzahlodergruenlandzahl','ackerzahlodergruenlandzahl','3','pixels','25833',,'0','100','28805','49','1000001',,'EPSG:25833',,'1.1.0','image/png','60',,,,,'1','0',,'Farbige Darstellung der BWZ für Grün-/Ackerland','Breede',,'0');
SET @last_layer_id50303602=LAST_INSERT_ID();
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 1 AND [ackerzahlodergruenlandzahl] < 21)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'255 204 241',,'255 204 241',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 21 AND [ackerzahlodergruenlandzahl] < 31)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'222 167 217',,'222 167 217',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 31 AND [ackerzahlodergruenlandzahl] < 41)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'189 130 193',,'189 130 193',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 41 AND [ackerzahlodergruenlandzahl] < 51)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'157 94 169',,'157 94 169',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 51 AND [ackerzahlodergruenlandzahl] < 61)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'124 57 145',,'124 57 145',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303602,'([ackerzahlodergruenlandzahl] >= 61 AND [ackerzahlodergruenlandzahl] < 71)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'92 21 121',,'92 21 121',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);

UPDATE layer_attributes SET options = REPLACE(options, '50303599', @last_layer_id50303599) WHERE layer_id IN(@last_layer_id50303599, @last_layer_id50303601, @last_layer_id50303600, @last_layer_id50303602) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
UPDATE layer_attributes SET options = REPLACE(options, '50303601', @last_layer_id50303601) WHERE layer_id IN(@last_layer_id50303599, @last_layer_id50303601, @last_layer_id50303600, @last_layer_id50303602) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
UPDATE layer_attributes SET options = REPLACE(options, '50303600', @last_layer_id50303600) WHERE layer_id IN(@last_layer_id50303599, @last_layer_id50303601, @last_layer_id50303600, @last_layer_id50303602) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
UPDATE layer_attributes SET options = REPLACE(options, '50303602', @last_layer_id50303602) WHERE layer_id IN(@last_layer_id50303599, @last_layer_id50303601, @last_layer_id50303600, @last_layer_id50303602) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');

Layer Klassifizierte Bodenwertzahlen pro Flurstück

Je ein Layer für Acker- und Grünland, außerdem je ein Layer für Acker-Grünland-Wechselland sowie Grünland-Acker-Wechselland.

SET @group_id = 1;
SET @connection = 'user=xxxx password=xxxx dbname=kvwmapsp';

INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen je Flurstück (A)',,'2',@group_id,,'lkvr_schaetzungsflaechen_flurstueck','wkb_geometry from (SELECT s.fsgml_id as oid, s.a_bwz_gesamt, f.wkb_geometry FROM alkis.lkvr_schaetzungsflaechen_flurstueck s, alkis.ax_flurstueck f WHERE s.fsgml_id = f.gml_id) as foo using unique oid using srid=25833','alkis',,,,,,NULL,NULL,,@connection,,'6','a_bwz_gesamt','a_bwz_gesamt','3','pixels','25833',,'0','100','28804','49','1000001',,'EPSG:25833',,'1.1.0','image/png','60',,,,,'1','0',,'Farbige Darstellung der BWZ für Acker','Breede',,'0');
SET @last_layer_id50303590=LAST_INSERT_ID();
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303590,'([a_bwz_gesamt] >= 1 AND [a_bwz_gesamt] < 21)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'255 250 179',,'255 250 179',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303590,'([a_bwz_gesamt] >= 21 AND [a_bwz_gesamt] < 31)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'224 208 143',,'224 208 143',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303590,'([a_bwz_gesamt] >= 31 AND [a_bwz_gesamt] < 41)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'193 166 107',,'193 166 107',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303590,'([a_bwz_gesamt] >= 41 AND [a_bwz_gesamt] < 51)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'162 124 72',,'162 124 72',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303590,'([a_bwz_gesamt] >= 51 AND [a_bwz_gesamt] < 61)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'131 82 36',,'131 82 36',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303590,'([a_bwz_gesamt] >= 61 AND [a_bwz_gesamt] < 71)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'101 40 1',,'101 40 1',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);

INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen je Flurstück (AGr)',,'2',@group_id,,'lkvr_schaetzungsflaechen_flurstueck','wkb_geometry from (SELECT s.fsgml_id as oid, s.agr_bwz_gesamt, f.wkb_geometry FROM alkis.lkvr_schaetzungsflaechen_flurstueck s, alkis.ax_flurstueck f WHERE s.fsgml_id = f.gml_id) as foo using unique oid using srid=25833','alkis',,,,,,NULL,NULL,,@connection,,'6','agr_bwz_gesamt','agr_bwz_gesamt','3','pixels','25833',,'0','100','28802','49','1000001',,'EPSG:25833',,'1.1.0','image/png','60',,,,,'1','0',,'Farbige Darstellung der BWZ für Acker-/Grünland','Breede',,'0');
SET @last_layer_id50303594=LAST_INSERT_ID();
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303594,'([agr_bwz_gesamt] >= 1 AND [agr_bwz_gesamt] < 21)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'204 255 252',,'204 255 252',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303594,'([agr_bwz_gesamt] >= 21 AND [agr_bwz_gesamt] < 31)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'170 226 222',,'170 226 222',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303594,'([agr_bwz_gesamt] >= 31 AND [agr_bwz_gesamt] < 41)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'137 197 193',,'137 197 193',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303594,'([agr_bwz_gesamt] >= 41 AND [agr_bwz_gesamt] < 51)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'103 168 164',,'103 168 164',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303594,'([agr_bwz_gesamt] >= 51 AND [agr_bwz_gesamt] < 61)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'70 139 135',,'70 139 135',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303594,'([agr_bwz_gesamt] >= 61 AND [agr_bwz_gesamt] < 71)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'37 111 106',,'37 111 106',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);

INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen je Flurstück (Gr)',,'2',@group_id,,'lkvr_schaetzungsflaechen_flurstueck','wkb_geometry from (SELECT s.fsgml_id as oid, s.gr_bwz_gesamt, f.wkb_geometry FROM alkis.lkvr_schaetzungsflaechen_flurstueck s, alkis.ax_flurstueck f WHERE s.fsgml_id = f.gml_id) as foo using unique oid using srid=25833','alkis',,,,,,NULL,NULL,,@connection,,'6','gr_bwz_gesamt','gr_bwz_gesamt','3','pixels','25833',,'0','100','28803','49','1000001',,'EPSG:25833',,'1.1.0','image/png','60',,,,,'1','0',,'Farbige Darstellung der BWZ für Grünland','Breede',,'0');
SET @last_layer_id50303592=LAST_INSERT_ID();
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303592,'([gr_bwz_gesamt] >= 1 AND [gr_bwz_gesamt] < 21)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'237 255 179',,'237 255 179',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303592,'([gr_bwz_gesamt] >= 21 AND [gr_bwz_gesamt] < 31)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'193 225 143',,'193 225 143',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303592,'([gr_bwz_gesamt] >= 31 AND [gr_bwz_gesamt] < 41)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'149 195 108',,'149 195 108',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303592,'([gr_bwz_gesamt] >= 41 AND [gr_bwz_gesamt] < 51)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'105 165 72',,'105 165 72',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303592,'([gr_bwz_gesamt] >= 51 AND [gr_bwz_gesamt] < 61)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'61 135 37',,'61 135 37',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303592,'([gr_bwz_gesamt] >= 61 AND [gr_bwz_gesamt] < 71)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'18 105 2',,'18 105 2',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);

INSERT INTO layer (`Name`,`alias`,`Datentyp`,`Gruppe`,`pfad`,`maintable`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`,`processing`,`kurzbeschreibung`,`datenherr`,`metalink`,`privileg`) VALUES('Bodenwertzahlen je Flurstück (GrA)',,'2',@group_id,,'lkvr_schaetzungsflaechen_flurstueck','wkb_geometry from (SELECT s.fsgml_id as oid, s.gra_bwz_gesamt, f.wkb_geometry FROM alkis.lkvr_schaetzungsflaechen_flurstueck s, alkis.ax_flurstueck f WHERE s.fsgml_id = f.gml_id) as foo using unique oid using srid=25833','alkis',,,,,,NULL,NULL,,@connection,,'6','gra_bwz_gesamt','gra_bwz_gesamt','3','pixels','25833',,'0','100','28801','49','1000001',,'EPSG:25833',,'1.1.0','image/png','60',,,,,'1','0',,'Farbige Darstellung der BWZ für Grün-/Ackerland','Breede',,'0');
SET @last_layer_id50303596=LAST_INSERT_ID();
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('1-20',@last_layer_id50303596,'([gra_bwz_gesamt] >= 1 AND [gra_bwz_gesamt] < 21)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'255 204 241',,'255 204 241',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('21-30',@last_layer_id50303596,'([gra_bwz_gesamt] >= 21 AND [gra_bwz_gesamt] < 31)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'222 167 217',,'222 167 217',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('31-40',@last_layer_id50303596,'([gra_bwz_gesamt] >= 31 AND [gra_bwz_gesamt] < 41)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'189 130 193',,'189 130 193',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('41-50',@last_layer_id50303596,'([gra_bwz_gesamt] >= 41 AND [gra_bwz_gesamt] < 51)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'157 94 169',,'157 94 169',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('51-60',@last_layer_id50303596,'([gra_bwz_gesamt] >= 51 AND [gra_bwz_gesamt] < 61)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'124 57 145',,'124 57 145',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('61-70',@last_layer_id50303596,'([gra_bwz_gesamt] >= 61 AND [gra_bwz_gesamt] < 71)','1',);
SET @last_class_id=LAST_INSERT_ID();
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,,,'92 21 121',,'92 21 121',NULL,'1','360',,NULL,NULL,NULL,NULL,);
 SET @last_style_id=LAST_INSERT_ID();
INSERT INTO u_styles2classes (style_id, class_id, drawingorder) VALUES (@last_style_id, @last_class_id, 0);

UPDATE layer_attributes SET options = REPLACE(options, '50303590', @last_layer_id50303590) WHERE layer_id IN(@last_layer_id50303590, @last_layer_id50303594, @last_layer_id50303592, @last_layer_id50303596) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
UPDATE layer_attributes SET options = REPLACE(options, '50303594', @last_layer_id50303594) WHERE layer_id IN(@last_layer_id50303590, @last_layer_id50303594, @last_layer_id50303592, @last_layer_id50303596) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
UPDATE layer_attributes SET options = REPLACE(options, '50303592', @last_layer_id50303592) WHERE layer_id IN(@last_layer_id50303590, @last_layer_id50303594, @last_layer_id50303592, @last_layer_id50303596) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');
UPDATE layer_attributes SET options = REPLACE(options, '50303596', @last_layer_id50303596) WHERE layer_id IN(@last_layer_id50303590, @last_layer_id50303594, @last_layer_id50303592, @last_layer_id50303596) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK', 'Autovervollständigungsfeld', 'Auswahlfeld');