Community of VE/MapPoint Users and Developers
This is a discussion on FindNearRoute with Virtual Earth 6.1 and SQL Server 2008 within the Virtual Earth Blogs forums, part of the Blogs category; Just last night we released a minor update to Virtual Earth. Besides the fact that we can now generate the ...
| |||||||
| Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| FindNearRoute with Virtual Earth 6.1 and SQL Server 2008 Just last night we released a minor update to Virtual Earth. Besides the fact that we can now generate the tokens for the Customer Identification and thus the transaction counting not only in the production- but also in the development environment we return now the complete route-geometry when you calculate a route. This feature is considered to be a 'premium feature' and is only available to enterprise customers who use the customer identification.* Having access to the route-geometry allows us for instance to have multiple routes on a map... ...or together with a spatial-enabled database such as SQL Server 2008 to implement a feature which returns points of interest in a buffer around a route. Let's have a look at the latter. IntroductionWhile we do have a FindNearRoute-feature in MapPoint Web Service (MWS) there is no such thing in Virtual Earth (VE) yet. To use this feature in MWS all the Points of Interest (POI) have to uploaded to a so called Custom Data Store (CDS) and then the calculation is done directly within the Microsoft Data Centres. Since SQL Server 2008 has many build-in spatial functions and since Virtual Earth version 6.1 exposes now the complete geometry of the route we can build such a feature ourselves. In previous postings I have introduced SQL Server 2008 and its integration with Virtual Earth so I won't go into the details here.
ConceptThe idea is to calculate the route with the VEMap.GetDirections-method. The VERoute-object which is returned will have several properties. One of these is the ShapePoints, basically an array of latitudes and longitudes. We will process this array and convert it into Well Known Text (WKT) of type LINESTRING which can later be used for the spatial-relationship query within SQL Server 2008. The WKT is then send along with the size of the buffer via AJAX-call to a web handler. The web handler executes now a stored procedure which calculates a buffer around our route and thereafter determines all POI within this buffer. The result will be processed through a string builder and returned to the client as JavaScript. ![]() ![]() Click here to view the article. Last edited by Eric Frost; 05-01-2008 at 10:22 AM. |
![]() |
| Tags |
| 2008, findnearroute, server, sql, virtual earth |
| ||||
| Posted By | For | Type | Date | |
| Technorati: Discussion about “FindNearRoute with Virtual Earth 6.1 and SQL Server 2008” | This thread | Refback | 06-15-2008 05:38 PM | |
| Latitude / Longitude DMS -> Decimal Converter - MP2K Magazine | This thread | Refback | 05-05-2008 11:56 PM | |
| The Magazine for MapPoint - MP2K Magazine | This thread | Refback | 05-01-2008 10:52 AM | |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Virtual Earth & SQL Server 2008 - Part 4: Integrating SQL Server 2008 and Virtual Earth (5/6) | Johannes Kebeck's Blog | Virtual Earth Blogs | 0 | 03-22-2008 08:13 AM |
| Virtual Earth & SQL Server 2008 - Part 4: Integrating SQL Server 2008 and Virtual Earth (1/6) | Johannes Kebeck's Blog | Virtual Earth Blogs | 0 | 03-02-2008 03:52 PM |
| Virtual Earth & SQL Server 2008 - Part 2: Spatial Data Management in SQL Server 2008 (3/3) | Johannes Kebeck's Blog | Virtual Earth Blogs | 0 | 03-02-2008 01:40 PM |
| Virtual Earth & SQL Server 2008 - Part 2: Spatial Data Management in SQL Server 2008 (2/3) | Johannes Kebeck's Blog | Virtual Earth Blogs | 0 | 03-02-2008 01:40 PM |
| Virtual Earth & SQL Server 2008 - Part 2: Spatial Data Management in SQL Server 2008 (1/3) | Johannes Kebeck's Blog | Virtual Earth Blogs | 0 | 03-02-2008 01:40 PM |
Ski Holidays Norway
Whether you are looking for a well-earned rest or just great Ski holidays, Norway is undoubtedly a great place to visit. Book online.
Portugal Holidays
Find great Portugal Holidays with Travel Counsellors. A personal Travel Counsellor can help you plan the perfect holiday to Portugal.
Holidays to Cuba
Situated between Jamaica and the Bahamas, Cuba has a delightful tropical climate and warm, clear waters with beaches of white sand. Check for cheap holidays to Cuba.
Sri Lanka Holidays
There are some outstanding deals on Sri Lanka holidays at theholidayplace.co.uk. Sri Lanka is renowned for it's exceptional beauty! Book a holiday today!
Cheap Balearics Holidays
Cheap Balearics holidays are available if you know when to book and who to book with. The Balearics have many fascinating places to visit all year round. The partying never stops.
Family Holidays
Family holidays can be great fun. Check out your options at Travel.co.uk
Holidays in Fuerteventura
Need a break? Go to the Canary Islands! Find information on holidays in Fuerteventura at On The Beach.