]> git.openstreetmap.org Git - nominatim.git/commitdiff
make it run with 64bit and 32bit osm2pgsql
authorSarah Hoffmann <lonvia@denofr.de>
Mon, 16 Apr 2012 22:17:05 +0000 (00:17 +0200)
committerSarah Hoffmann <lonvia@denofr.de>
Thu, 26 Apr 2012 19:11:51 +0000 (21:11 +0200)
Needs tweaking on the osm2pgsql side, too: the osmid column
needs to have the same format as in osm2pgsql. That means
that the changes are still not compatible with existing installations.

sql/tables.sql

index 385e1fc90d1fcba3fa7ba0329f72bd59d94cbe73..ff9c1c50fa515a0b7ee5ad76f9dc1555a0de070b 100644 (file)
@@ -191,18 +191,7 @@ drop table placex;
 CREATE TABLE placex (
   place_id BIGINT NOT NULL,
   partition integer,
-  osm_type char(1),
-  osm_id BIGINT,
-  class TEXT NOT NULL,
-  type TEXT NOT NULL,
-  name HSTORE,
-  admin_level INTEGER,
-  housenumber TEXT,
-  street TEXT,
-  isin TEXT,
-  postcode TEXT,
-  country_code varchar(2),
-  extratags HSTORE,
+  LIKE place INCLUDING CONSTRAINTS,
   parent_place_id BIGINT,
   linked_place_id BIGINT,
   rank_address INTEGER,
@@ -212,7 +201,6 @@ CREATE TABLE placex (
   indexed_date TIMESTAMP,
   geometry_sector INTEGER
   );
-SELECT AddGeometryColumn('placex', 'geometry', 4326, 'GEOMETRY', 2);
 SELECT AddGeometryColumn('placex', 'centroid', 4326, 'GEOMETRY', 2);
 CREATE UNIQUE INDEX idx_place_id ON placex USING BTREE (place_id);
 CREATE INDEX idx_placex_osmid ON placex USING BTREE (osm_type, osm_id);