Nearest vehicle/person to a geocode RRS feed

  • Question

  • Hi,

    We have several vehicles which will be sending us geoocodes.
    We save these geocodes in our database.

    If i pass a geocode, i want to get the nearest vehicle to the geocode sent.

    Is there a built in function for this in Bing Maps?


    • Moved by Ricky_Brundritt Saturday, March 10, 2012 12:25 PM (From:Bing Maps: Map Control and Web services Development)
    Friday, December 9, 2011 7:57 PM


All replies

  • This can be done fairly easily. You will need a web service that you can use to connect the webpage to your database. You can then send the coordinate of where you want to look nearby to the server and then look for nearby coordinates in your database. If you are using SQL 2008 or SQL azure you may find this project useful:

    Alternatively if you are using one of those databases you simply need a simple SQL command that uses STDistance: and here is an article that uses it:

    Note that this is a asset tracking application that you are creating and there are special terms of use in this regards: Basically you need a license to use Bing Maps if you are doing asset tracking. Contact the licensing department for more information here:
    Saturday, December 10, 2011 8:40 AM
  • Hello Richard,


       We do have the licence and we are using the bing maps. 

    I was told that there is a inbuilt function in bing maps which will take geocodes of the vehicles, current geocode of the client and the anchor geocode( first location where the vehicle should go) as the parameters and the Estimated Time will be returned for that function. So that the vehicle will know, whether it should pick that client or not.

    However, I was not sure if this exists or not. Just wanted to check with you.




    Monday, December 12, 2011 4:00 PM