This month's discount Comprehensive Database Performance Health Check · Testimonials
SQLAuthority with Pinal Dave
Home
  • Consulting
    • Health Check
  • Free Videos
  • All Articles
    • AI
    • SQL Performance
    • SQL Tips and Tricks
    • Interview Questions and Answers
    • SQL Puzzle
    • SQL Video
    • SQLAuthority News
    • Personal
  • Books
  • Consulting
Gouache painting of three objects on a table: tall columns of stacked colored tiles, a corkboard with pins joined by threads in a network with one vermilion thread, and a small globe on a stand.

Columnar, Graph and Spatial Databases: Three Shapes of Data

October 18, 2013
Pinal Dave
SQL Tips and Tricks
ColumnStore Index, Data Warehousing, Database, Spatial Database

Columnar, Graph and Spatial Databases are three data models built for three kinds of questions: totals over many rows, paths through relationships, and distances between places. This post explains each one and builds all three in SQL Server 2025 with columnstore, graph tables and the geography type.

Read More
SQL SERVER - Beginning SQL 2012 - Spatial Unions and Collections

SQL SERVER – Beginning SQL 2012 – Spatial Unions and Collections

February 27, 2013
Pinal Dave
SQL Tips and Tricks
Joes 2 Pros, Spatial Database, SQL Scripts, SQL Server

Aggregates are not just for sales totals. Much like a jigsaw puzzle, spatial unions assemble land coordinates together. Learn spatial unions and collections in SQL 2012.

Read More
Gouache painting of a balance scale where one small framed painting with a red frame outweighs a heap of pebbles

Draw Pictures with T-SQL: The SSMS Spatial Results Tab

September 28, 2012
Pinal Dave
SQL Tips and Tricks
Spatial Database, SQL Scripts, SQL Server Management Studio

The SSMS Spatial results tab draws every geometry value a query returns. This post draws a house and a tree with STGeomFromText and STBuffer, explains labels and the 5,000 object limit, and checks store service areas for overlaps and gaps.

Read More
SQL Server Spatial object invalid due to overlapping edges.

SQL SERVER – Validating Spatial Object as NULL using IsNULL

June 30, 2012
Pinal Dave
SQL Tips and Tricks
Spatial Database, SQL Function

How do spatial functions handle NULL? I show two ways of validating a spatial object as NULL: the IsNULL method, which returns 0 or NULL, and IsValidDetailed.

Read More
SQL SERVER - Validating Spatial Object with IsValidDetailed Function

SQL SERVER – Validating Spatial Object with IsValidDetailed Function

June 29, 2012
Pinal Dave
SQL Tips and Tricks
Spatial Database, SQL Scripts

Invalid spatial objects used to give only a simple error. The IsValidDetailed function tells you whether a shape is valid and, when it is not, the reason why.

Read More
A graph plotting data points on a coordinate grid.

SQL SERVER – Finding Shortest Distance between Two Shapes using Spatial Data Classes – Ramsetu or Adam’s Bridge

March 18, 2012
Pinal Dave
SQL Tips and Tricks
Spatial Database, SQL Function

Using ShortestLineTo in SQL Server spatial data classes, I find the shortest distance between two shapes, with a fun Ramsetu, or Adam’s Bridge, example.

Read More
An open wooden case holding a terracotta tile beside blue and pale stones.

geometry STAsBinary: Carry the SRID Beside the WKB

June 12, 2011
Pinal Dave
SQL Tips and Tricks
Spatial Database, SQL Function, SQL Scripts, SQL Server

geometry STAsBinary exports a geometry as WKB, while reconstruction takes a separate spatial reference identifier. I carry that identifier beside the bytes. Supplying a different identifier creates a differently tagged value from the same exported coordinates.

Read More
Previous 1 2 3 4 5 6 Next
  • Books
  • Testimonials
  • Privacy Policy

© 2006 – 2026 All rights reserved. pinal @ SQLAuthority.com