0

Do we need spatial index for point type geometry in SQL Server?

If yes, how Tessellation and grid selections work in point type geometry?

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
ShreyasK
  • 15
  • 3
  • 1
    As with any other indexing concern, the choice of index will be informed by what sorts of predicates you intend for it to optimize and what the distribution of the data is. That said, I haven't seen the tessellation (and grid is a property of the tessellation) matter too much; I'd try different configurations to see if it makes a material difference for your use case. – Ben Thul Jan 10 '22 at 21:55
  • Thanks @BenThul, as i learned from microsoft documentation, It creates grid on square bounding box area of shape, geometry and then splits with number of cells per object. but incase of point there is no area neither bounding box. In that case how spatial index creates cells/grid/bounding box? – ShreyasK Jan 11 '22 at 15:02
  • Again, it's "in what context do you expect the index to be used?". A relevant question here is - in what space are you envisioning trying to find these points? An example answer is "all of my points will be in the box defined by corners (0, 0), (1000, 1000)". In that case, that would define the bounding box for the index that supports queries for those points. Because you're dealing with geometry data, it's inherently the Cartesian plane so you'll need to define *some* bounding box. – Ben Thul Jan 11 '22 at 17:28

0 Answers0