Created
December 16, 2016 15:32
-
-
Save ramiroaznar/d1eb1579652d7560800529e8f32ccb02 to your computer and use it in GitHub Desktop.
Update several columns from CARTO geocoding
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
update mad_comm_routes m1 | |
set (minutes,kilometers,the_geom) = | |
( | |
select | |
b.duration, | |
b.length, | |
b.shape | |
from | |
mad_comm_routes a, | |
cdb_route_point_to_point( | |
cdb_latlng(a.lat_o, a.long_o), | |
cdb_latlng(a.lat_d, a.long_d), | |
'car') as b | |
where a.cartodb_id = m1.cartodb_id | |
) | |
where the_geom is null and | |
cartodb_id between 1 and 1000 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment