15
SQL Server 2008 R2 Spatial Data Notes
Building a Point
A point in SQL Server is represented as Longitude and then Latitude
geography::STPointFromText(‘POINT(‘ + CAST([Longitude] AS VARCHAR(20)) + ‘ ‘ + CAST([Latitude] AS VARCHAR(20)) + ‘)’, 4326)
Ring Orientation
A ring is a collection of points that make up a polygon. A ring either defines an area inside or outside of the polygon. Defining the points of a ring in a counter-clockwise manner means you want to include everything within the ring. Defining the ring in a clockwise pattern means you want to include everything outside the ring.
Hemispheres
You cannot cross hemispheres when defining a polygon. This includes the Northern/Southern hemispheres as well as the hemispheres defined as East/West of the Prime Meridian.
Longitude
Longitude is defined as numbers between -180 and +180
Latitude
Latitude is defined as numbers between -90 and +90
Leave a comment
Blogroll
@benmarch
- RT @MOJOmn: What Does A VC Mean When He Says Your Product Is “A Feature And Not A Company”? http://t.co/L6xxaiZW - you'll get no $
- RT @pclindeman: Interesting Read: How Companies Learn Your Secrets: http://t.co/YZ7x47VO
- Had a great first day at http://t.co/dKlmltdx. Looking forward to tomorrow!
- @BizDevTalk I'm at buyfun.com in North Mankato.
- @coreybuzzell Yep, first day. It was great. I think it was a good move.
Tag Cloud!
Knowledge Bomb
- January 2012 (2)
- December 2011 (1)
- May 2011 (1)
- February 2011 (2)
- September 2010 (1)
- August 2010 (2)
- June 2010 (1)
- May 2010 (1)
- April 2010 (10)
- March 2010 (1)







