Changes between Version 16 and Version 17 of RNABE download and load
- Timestamp:
- May 21, 2010 2:32:04 PM (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
RNABE download and load
v16 v17 17 17 REM se placer dans le répertoire ou sont les données 18 18 D: 19 cd D:\Celine Jouanin\RNABE\France 19 cd D:\Celine Jouanin\RNABE\France_RW 20 20 }}} 21 21 {{{ 22 C:\"Program Files"\PostgreSQL\8.4\bin\shp2pgsql -s 4258 -I RWBody_Merge.shp RWBody >RWBody.sql22 C:\"Program Files"\PostgreSQL\8.4\bin\shp2pgsql -s 4258 -I Fr_RWBody_Merge.shp Fr_RWBody > Fr_RWBody.sql 23 23 }}} 24 24 * Convert it into utf8 (as the database is posgis), in notepad, open the stationsp.sql file and convert it to utf8 25 25 Encodage> Convertir en UTF-8 26 26 27 And save the file as : RWBodyutf827 And save the file as : Fr_RWBodyutf8 28 28 29 29 30 30 * Use psql to restore the file while connecting to eda2.0 ... change the port if necessary (cedric : 5433) 31 31 {{{ 32 C:\"Program Files"\PostgreSQL\8.4\bin\psql -d eda2.0 -h localhost -U postgres -p 5432 -f RWBodyutf8.sql32 C:\"Program Files"\PostgreSQL\8.4\bin\psql -d eda2.0 -h localhost -U postgres -p 5432 -f Fr_RWBodyutf8.sql 33 33 }}} 34 34 … … 37 37 --- In sql editor 38 38 CREATE SCHEMA RNABE; 39 ALTER TABLE rwbody SET SCHEMA rnabe; 40 select SRID (the_geom) FROM rnabe.rwbody; 39 ALTER TABLE fr_rwbody SET SCHEMA rnabe; 41 40 }}} 42 41 … … 44 43 La projection du RNABE est en fait l'ETRS89 et non pas l'ETRS89-LAEA [[BR]] 45 44 Il faut donc changer le srid 4258 (ETRS89) en 3035 ( ) [[BR]] 46 47 45 {{{ 46 -- Problème de script ne fonctionne pas 47 select SRID (the_geom) FROM rnabe.fr_rwbody; 48 SELECT addGeometryColunm('fr_rwbody','the_geom',3035,'MULTILINESTRING',2); 49 UPDATE rnabe.fr_rwbody SET the_geom = ST_tranform(the_geom,3035); 50 }}} 48 51 49 52 == Autre façon d'importer les données ==