| 14 | ALTER TABLE clc.clipped_bretagne add column id serial PRIMARY KEY; |
| 15 | -- ajout dans la table geometry_columns pour référencement rapide sous Qgis |
| 16 | INSERT INTO geometry_columns(f_table_catalog, f_table_schema, f_table_name, f_geometry_column, coord_dimension, srid, "type") |
| 17 | SELECT '', 'clc', 'clipped_bretagne', 'the_geom', ST_CoordDim(clipped_geom), ST_SRID(clipped_geom), MULTIPOLYGON |
| 18 | FROM clc.clipped_bretagne LIMIT 1; |
| 20 | -- il ne s'affiche pas... essai réduit OK |
| 21 | DROP TABLE IF EXISTS clc.clipped_bretagne; |
| 22 | CREATE TABLE clc.clipped_bretagne AS |
| 23 | SELECT clc.gid as clcgid,c.gid, clc.the_geom FROM clc.clc00_v2_europe clc INNER JOIN ccm21.catchments c |
| 24 | ON ST_Intersects (c.the_geom,clc.the_geom) |
| 25 | WHERE c.wso_id IN (SELECT wso_id FROM france.wso WHERE area='Bretagne') |
| 26 | AND substring(code_00 from 1 for 1)='1'; |
17 | | -- ajout dans la table geometry_columns pour référencement rapide sous Qgis |
18 | | |
19 | | INSERT INTO geometry_columns(f_table_catalog, f_table_schema, f_table_name, f_geometry_column, coord_dimension, srid, "type") |
20 | | SELECT '', 'clc', 'clipped_bretagne', 'the_geom', ST_CoordDim(clipped_geom), ST_SRID(clipped_geom), GeometryType(clipped_geom) |
21 | | FROM clc.clipped_bretagne LIMIT 1; |