Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is a SPATIAL INDEX and when should I use it?

Like most of the average PHP web developers I use MySql as a RDBMS. MySql (as other RDBMS also) offers SPATIAL INDEX features, but I'm don't get it very well. I have googled for it but didn't find clear real world examples to clarify my bad knowledge about it.

Could someone explain me a little bit what is a SPATIAL INDEX and when should I use it?

like image 616
demian Avatar asked Feb 13 '10 03:02

demian


People also ask

What is a spatial index used for?

A spatial index is a type of extended index that allows you to index a spatial column. A spatial column is a table column that contains data of a spatial data type, such as geometry or geography.

Why are spatial indexing capabilities important in spatial databases?

Indexes make using a spatial database for large data sets possible. Without indexing, any search for a feature would require a “sequential scan” of every record in the database. Indexing speeds up searching by organizing the data into a search tree which can be quickly traversed to find a particular record.

What is a spatial index Arcmap?

The spatial index is defined by using a grid-based system that spans the extent of the features in a feature class, like a locator grid you might find on a common road map. By default, ArcGIS creates and maintains a spatial index for geodatabase feature classes.

What is spatial index in mysql?

SPATIAL INDEX creates an R-tree index. For storage engines that support nonspatial indexing of spatial columns, the engine creates a B-tree index. A B-tree index on spatial values is useful for exact-value lookups, but not for range scans.


1 Answers

You can use a spatial index for indexing geo-objects - shapes. The spatial index makes it possible to efficiently search for objects that overlap in space

like image 92
Roland Bouman Avatar answered Oct 24 '22 18:10

Roland Bouman