background preloader

Virtualearth

Facebook Twitter

REST

Analytics. Hannes's Virtual Earth Blog: SQL Server 2008. Showing ESRI Shapefile Layers on a Virtual Earth Map - a simple. Minus34. Master/Detail with ASP.NET AJAX and the MS Virtual. I was recently working on a research project with the purpose of exploring how ASP.NET AJAX could be combined with Microsoft's Virtual Earth Map Control to implement the common master - details UI pattern. Our application allows users to browse zip-codes using the Virtual Earth Map Control and we thought it would be useful to display details for the zip-code as it was being hovered over. While investigating this I created a prototype web application that does the following: Renders purple polygons on the VEMap surface representing the following 3 zip-codes: 32224, 32246, and 32256. When the user hovers over the polygons, 2 things happen: The border of the polygon changes to a thicker width.

This is a visual cue meant to inform the user of their action The information displayed in the table to the right of the map updates. Live Demo | Download Here is a brief explanation of how I accomplished this. Load the Map First I added a HTML div element to the page that will contain the map. Dave does Data. Spatial Ed. Bob Beauchemin's Blog | Using SQL Server 2008 spatial and t. This entry is a continuation of the previous posting on how to use SQL Server 2008 spatial data and Virtual Earth. This entry discusses your web service and SQL Server code choices. The point of the web service is to translate one of the output formats of SQL Server 2008 spatial to a format this Virtual Earth can use. The spatial data types can be output in: 1. Well-known text format 2. "Native" format – that is, return a Geometry/Geography type to a .NET client as the SqlGeometry/SqlGeography native .NET types 3.

GML – Geography markup language Remember that Virtual Earth needs: 1. There is not a one-to-one correspondence between any of these methods, so there is going to be a need for a transformation somewhere. Finally, there could be a pushpin (point) associated with the center of a polygon and/or text associated with the pushpin. Because there are many ways to process XML in SQL Server and in web services, that's lots of choices.

Hannes's Virtual Earth Blog: SQL Server Spatial. Dave does Data. Spatial Ed : Working with Invalid Data and the SQL Server 2008 G. "Fixing" Polygon Ring Orientation in SQL Server 2008 using T-SQL In the last installment, I promised to try and correct invalid Geography data using FME. While I am making progress on that front, I decided to take a small detour and discuss an interesting but little known behavior of the SQL Server Geometry type, polygons and data validation. One of the most common data errors when attempting to import spatial data into the Geography data type involves the ring orientation of polygons: A .NET Framework error occurred during execution of user-defined routine or aggregate "geography": Microsoft.SqlServer.Types.GLArgumentException: 24205: The specified input does not represent a valid geography instance because it exceeds a single hemisphere.

Each geography instance must fit inside a single hemisphere. A common reason for this error is that a polygon has the wrong ring orientation. Consequently, we often see inquiries about changing ring orientation in SQL Server, using T-SQL. Virtual Earth and SQL 2008 Spatial, a first impression. Article by: John O'Brien. Virtual Earth is an amazing platform to visualise location based data over a simple web connection. By combining the images provided by Microsoft’s platform with your own data, geo-coded to its real world location, you can create an engaging, interactive experience for your users. You can also visually represent vast sets of data in ways impossible to do otherwise. SQL Server 2008 is scheduled for release early next year. So what are these new features? SQL 2008 provides two new data types, geometry and geography.

For Virtual Earth our data type is a simple choice - Geography. There are a set of spatial functions that can be executed against these data types. DECLARE @g geography; DECLARE @h geography; SET @g = geography::STGeomFromText('POLYGON((47.653 -122.358, 47.649 -122.348, 47.658 -122.348, 47.658 -122.358, 47.653 -122.358))', 4326); SET @h = geography::STGeomFromText('POINT(47.656 -122.350)', 4326); select @h.STIntersects(@g); Creating a Spatial Field Map.js. The prototype property of JavaScript 1.1.

Putting things into perspective- Examples If you're having a hard time staying awake while reading this tutorial, I can't say I blame you. The prototype object of JavaScript isn't exactly as flashy and fun to learn as say, document.bgColor or window.open, and the rewards aren't always instant. But if you're at all interested in extending JavaScript and creating your own objects and libraries, the prototype object is a must learn. Allow me to show you now a couple of practical examples on using the prototype object of JavaScript: -Example 1-Extending functionality to the pre-built string() object As mentioned earlier in this tutorial, the prototype object can be used on pre-built JavaScript objects created with the new keyword to add custom properties/ methods to them.

The above code may not look like much, but it just added a whole new functionality to the default string object- the ability to output any text backwards! <script type="text/javascript"> var message1="Welcome to my site! " Virtual Earth Meets SQL Server 2008 and ASP.NET AJAX. More Concise T-SQL with SQL Server 2008. Total votes: 0 Views: 13,429 Comments: 0 Category: SQL Print: Print Article Please login to rate or to leave a comment. Monthly tip #3: Scott Mitchell reveals some SQL tips. Transact -SQL (or T-SQL), is Microsoft's extension to the SQL standard. It offers a host of system functions, local variable syntax and semantics, control flow constructs like WHILE and IF statements, TRY...CATCH error handling, and assorted enhancements to core SQL constructs.

T-SQL syntax has always been more similar to Visual Basic than to C# - its syntax is verbose and uses keywords like BEGIN and END and NOT, rather than curly braces or other punctuation. For starters, T-SQL 2008 now allows variables to be declared and initialized on a single line. 2.DECLARE @TheAnswerToEverything int, 3. 5.SET @TheAnswerToEverything = 42 6.SET @Author = 'Douglas Adams' With T-SQL 2008 you can now declare the variable and initialize it in the same statement: 3.Variables can now be declared and initialized in the same statement 5. 02.