After searching for a SQL Server TSQL implementation of Geohash types and conversion functions, I finally just went and wrote a whole open-source library myself:
- Github: QalGeohash-TSQL
I designed it for maximum accuracy, performance, and strong conversion consistency guarantees. It enables an average IT data warehouse analyst or report writer to efficiently use, process, and leverage simple GIS spatial proximity models and queries. Given the steep learning curve of finding and adopting a full GIS style solution for data-science/big-data/data-analytics, this library can enable a temporary or good-enough solution until new requirements require investing in a more fleshed out GIS solution like Mapbox, ESRI, etc.
It provides two Geohash implementation types; Integer (BIGINT) and String (VARCHAR). It also provides two coordinate types; Longitude+Latitude and DMS. And then it provides the conversions to and from these various types. It also provides conversions to/from the SQL Server spatial geography Point type.
Please see the README.md for detailed information.
Top comments (0)