cdb_bulk_geocode_street_point functions

This commit is contained in:
Juan Ignacio Sánchez Lara
2018-06-11 16:12:29 +02:00
parent 3f08d37ef7
commit 34fc6439d2
5 changed files with 173 additions and 0 deletions

View File

@@ -2341,6 +2341,13 @@ RETURNS VOID AS $$
config = RateLimitsConfig(service=service, username=username, limit=limit, period=period)
config_setter.set_server_rate_limits(config)
$$ LANGUAGE plpythonu VOLATILE PARALLEL UNSAFE;
-- TODO: could cartodb_id be replaced by rowid, maybe needing extra care for offset?
CREATE TYPE cdb_dataservices_server.geocoding AS (
cartodb_id integer,
the_geom geometry(Multipolygon,4326),
metadata jsonb
);
CREATE OR REPLACE FUNCTION cdb_dataservices_server.cdb_geocode_admin0_polygon(username text, orgname text, country_name text)
RETURNS Geometry AS $$
from cartodb_services.metrics import QuotaService