A View Inside My Head

Jason's Random Thoughts of Interest
posts - 86, comments - 178, trackbacks - 22

March 2009 Entries

For Jeff: Spatial Querying

A quick sample of usage as requested by my friend Jeff McWherter: Querying for all data in a table where the "zip code polygon" is within 20 miles of a geocode point (must convert 20 miles to meters in the predicate):: select * from dbo.fe_2007_us_zcta500 where Boundary.STDistance('POINT(-79.8884595930576 43.2609696686268)') < (20 * 1609.344)

posted @ Wednesday, March 04, 2009 6:08 PM | Feedback (1) | Filed Under [ SQL Spatial ]

Powered by: