Brian Quinion [Tue, 22 May 2012 14:27:42 +0000 (16:27 +0200)]
DB Scheme changes: alter table placex add column calculated_country_code varchar(2);
function changes:
-----------------
Move to ST_PointOnSurface from ST_Centroid in various places to avoid looking up a point outside the polygon
Move to ST_Covers from ST_Contains to include points on admin boundaries
Re-order preference for get_country_code now our data is better. country_osm_grid is now the preffered source.
Fix code to calculate country code in placex_insert, rank_search test was too early
Add extra field to placex 'calculated_country_code' to improve structure of code
Move split_geometery function out of add_location into its own function
Rewrite split_geometery to be more efficient.
Change place_insert to do more updates and less delete/inserts (delete is slow)
Include wikipedia links in details.php ouput
Cleanup no longer used geometry validation (adding overhead)
Include debug statements in function.sql (--DEBUG: ) and add flag to setup.php to turn them on
setup.php:
----------
add flag --disable-token-precalc to speed up debuging
add flag --index-noanalyse to disable analysising DB at rank 4 and 26 (previously removed, but on my local DB it seems to be required)
add flag --enable-diff-updates (modifier to --create-functions) to turn on the code required for diff updates without having to modify functions.sql
add flag --enable-debug-statements (modifier to --create-functions) to turn on debug warning statements
update.php:
-----------
added flag --no-index to import osmosis changes without indexing them
extend the hack to allow import of JOSM generated osm files
country_grid.sql - reference copy of the sql used to generate the country_osm_grid table, needs cleanup
Sarah Hoffmann [Mon, 16 Apr 2012 22:17:05 +0000 (00:17 +0200)]
make it run with 64bit and 32bit osm2pgsql
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.
Brian Quinion [Sun, 1 Apr 2012 00:40:50 +0000 (01:40 +0100)]
Adds code to merge place polygon and points using:
label relation member
admin_center, admin_centre relation member (with same name)
exact name, search_rank and location match
Adding this requires a new column and index:
SELECT AddGeometryColumn('placex', 'centroid', 4326, 'GEOMETRY', 2);
CREATE INDEX idx_placex_linked_place_id ON placex USING BTREE (linked_place_id);
Brian Quinion [Thu, 22 Mar 2012 00:33:28 +0000 (00:33 +0000)]
Use GB postcode table as definitive source. resort by pressence of search word in output address and other misc very minor changes not commited from MQ servers
Sarah Hoffmann [Tue, 20 Mar 2012 23:40:35 +0000 (00:40 +0100)]
Black/whitelisting for special phrases
Allows to restrict the special phrases imported from the wiki.
Blacklist allows to exclude certain class/type combinations.
Whitelist allows to define an allowed subset of types for a class.
Adjust to your liking in settings/phrase_settings.php before running
the specialphrases script.
Sarah Hoffmann [Fri, 9 Mar 2012 22:47:25 +0000 (23:47 +0100)]
restrict deferred delete to concerned place
Deleting by osm_type/osm_id goes wrong if the place was reimported
because of a change in geometry, admin_level etc. The newly created
place is deleted as well in this case.
Sarah Hoffmann [Fri, 10 Feb 2012 21:01:35 +0000 (21:01 +0000)]
during initial setup defer creation of non-vital until after nominatim indexing,
analyse DB during nominatim indexing so the query planer uses indexes correctly
Sarah Hoffmann [Sat, 21 Jan 2012 10:21:42 +0000 (10:21 +0000)]
- remove dependency on intarray extension
- new config options for postgresql version and
location of osm2pgsql and osmosis binaries
- new option --no-npi for update.php that supresses writing of NPIs in
osmosis update mode
- add more GRANTs for www-data