Solved

Plot multiple markers on google maps with spatial data

Posted on 2011-03-14
1
1,222 Views
Last Modified: 2012-05-11
Dear Experts,

I have a table holding spatial data in SQL 2008.  I would like to be able to plot this data onto a google map.  The data is returned via a recordset using classic ASP.

Can anyone point me in the right direction.

Thanks
0
Comment
Question by:grantballantyne
1 Comment
 
LVL 6

Accepted Solution

by:
worthyking1 earned 500 total points
ID: 35209605
When you say "spatial data" do you mean Lat/Long coordinates?

If you don't want anything fancy, just a static Google Map (without zoom etc.) then just use this URL to embed it:

http://maps.google.com/maps/api/staticmap?center=Brooklyn+Bridge,New+York,NY&zoom=14&size=512x512&maptype=roadmap
&markers=color:blue%7Clabel:A%7C40.702147,-74.015794&markers=color:green%7Clabel:B%7C40.711614,-74.012318
&markers=color:red%7Ccolor:red%7Clabel:C%7C40.718217,-73.998284&sensor=false

The above example is centered on the brooklyn bridge with three different color markers. Add as many markers as you want with the URL Param 'marker' like so:

&markers=color:blue%7Clabel:A%7C40.702147,-74.015794

For dynamic Javascript maps you can check out more in-depth methods here:

http://code.google.com/apis/maps/documentation/javascript/tutorial.html
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses the difference between strict equality operator and equality operator in JavaScript. The Need: Because JavaScript performs an implicit type conversion when performing comparisons, we have to take this into account when wri…
Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question