<div dir="ltr">Hi there,<div><br></div><div>I wasn't aware that was against the terms and conditions. Thanks for the tip.</div><div><br></div><div style>I've therefore had a look around and found this open source alternative. So same question as above, but please consider this instead of Google! :-)</div>

<div style><br></div><div style>Thanks</div><div style><br></div><div style>James</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On 16 May 2013 17:05, Travis Kirstine <span dir="ltr"><<a href="mailto:traviskirstine@gmail.com" target="_blank">traviskirstine@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>I don't think this would be permitted based on Google's terms of service, for example:<br>
<br>
</div>Section 10.1.3 <u>Restrictions against Data Export or Copying.</u><div><br>(b) <u>No Pre-Fetching, Caching, or Storage of Content.</u> You must not
      pre-fetch, cache, or store any Content, except that you may store:
      (i) limited amounts of Content for the purpose of improving the
      performance of your Maps API Implementation if you do so temporarily
      (and in no event for more than 30 calendar days),
      securely, and in a manner that does not permit use of the Content
      outside of the Service; and (ii) any content identifier or key that
      the Maps APIs Documentation specifically permits you to store. For
      example, you must not use the Content to create an independent
      database of "places" or other local listings information.<br><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote"><div><div class="h5">On 16 May 2013 11:01, James David Smith <span dir="ltr"><<a href="mailto:james.david.smith@gmail.com" target="_blank">james.david.smith@gmail.com</a>></span> wrote:<br>


</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr">Hi there,<div><br></div><div>This isn't so much a question as such, more a request for opinions and advice. I was wondering whether anyone had any experience with using the Google API for getting driving directions/routing - but then storing the results in a PostgreSQL/PostGIS database. I was thinking that my workflow might go something like this:</div>




<div><br></div><div>1) Take table of trip_ids, start points, end points, travel modes and start times from the database</div><div>2) Export them as a CSV</div><div>3) Import the CSV to R</div><div>

4) Use R to loop through the data and send queries off to the Google API.</div><div>5) The results are a series of polylines each with the geometry as a polyline, the length of the stage, the time of the stage etc. As a JSON file. If I could break this apart in it's constiuent parts, could I then store it back in my PostGIS database?</div>




<div><br></div><div>I guess the hardest bit I can see about this process, is converting the google encoded polyline to a PostGIS polyline I think. Any thoughts on that?</div><div><br></div><div>Once this is all done I then want to use the routes with another layer to calculate someones exposure to X over each journey.</div>




<div><br></div><div>Any general thoughts about this process would be welcome.</div><div><br></div><div>Thanks</div><span><font color="#888888"><div><br></div><div>James</div></font></span></div>
<br></div></div>_______________________________________________<br>
postgis-users mailing list<br>
<a href="mailto:postgis-users@lists.osgeo.org" target="_blank">postgis-users@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users" target="_blank">http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users</a><br>
<br></blockquote></div><br></div>
<br>_______________________________________________<br>
postgis-users mailing list<br>
<a href="mailto:postgis-users@lists.osgeo.org">postgis-users@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users" target="_blank">http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users</a><br>
<br></blockquote></div><br></div>