From 7ea0c31bce93dddcd4999c1171071cdd9469c022 Mon Sep 17 00:00:00 2001 From: =?utf8?q?St=C3=A9phane=20Jacob?= Date: Tue, 15 Mar 2011 08:15:14 +0100 Subject: [PATCH] Only geocodes addresses that were already geocoded. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Stéphane Jacob --- upgrade/1.0.1/merge_issues_geocoding.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/upgrade/1.0.1/merge_issues_geocoding.php b/upgrade/1.0.1/merge_issues_geocoding.php index 6f9016e..df98463 100755 --- a/upgrade/1.0.1/merge_issues_geocoding.php +++ b/upgrade/1.0.1/merge_issues_geocoding.php @@ -9,12 +9,14 @@ $globals->debug = 0; // Do not store backtraces. print "Tries to geocode addresses (due a bug in the previous release, all addresses must run once again).\n"; $time = XDB::fetchOneCell('SELECT COUNT(distinct(pid), jobid) - FROM profile_addresses'); + FROM profile_addresses + WHERE accuracy IS NOT NULL AND accuracy > 0'); $time = ceil($time / 60 / 24); print "It will approximately take $time days.\n"; $it = XDB::rawIterator('SELECT * FROM profile_addresses + WHERE accuracy IS NOT NULL AND accuracy > 0 ORDER BY pid, jobid, type, id'); $total = $it->total(); $i = 0; -- 2.1.4