From the course: Advanced SQL for Data Scientists

Unlock the full course today

Join today to access over 22,400 courses taught by industry experts or purchase this course individually.

GiST and SP-GiST indexes

GiST and SP-GiST indexes

From the course: Advanced SQL for Data Scientists

Start my 1-month free trial

GiST and SP-GiST indexes

- [Instructor] GiST and SP-GiST indexes are specialized index provided by Postgres. Now, GiST stands for Generalized Search Tree, and it's basically, it's a balanced tree structure method. And GiST is used as a template to actually implement other indexing schemes. So depending on our data structure, we can use a GiST index. So for example, one could build a B-tree index, which is a self-balancing tree, or an R-trees which are used with multi-dimensional data. So these, for example, with geographic coordinates. Now, that GiST is used in Postgres for indexing things like hstore and ltree. These are two data types that we're going to delve into much more deeply, later in the course. But I just wanted to point out that GiST indexes are used for these specialized data types. Now, when we talk about indexes and data types we also have to talk about operators and what kind of objects can the operators apply to. So in the case of…

Contents