• Why aren’t PostgreSQL R-Tree indexes supported?

    作者:  • 2006 年 12 月 6 日 • 技术主义 • 暂无评论

    From PostGIS Manual: Early versions of PostGIS used the PostgreSQL R-Tree indexes. However, PostgreSQL R-Trees have been completely discarded since version 0.6, and spatial indexing is provided with an R-Tree-over-GiST scheme.
    Our tests have shown search speed for native R-Tree and GiST to be comparable. Native PostgreSQL R-Trees have two limitations which make them undesirable for use with GIS features (note that these limitations are due to the current PostgreSQL native R-Tree implementation, not the R-Tree concept in general):

    1. R-Tree indexes in PostgreSQL cannot handle features which are larger than 8K in size. GiST indexes can, using the “lossy” trick of substituting the bounding box for the feature itself.
    2. R-Tree indexes in PostgreSQL are not “null safe”, so building an index on a geometry column which contains null geometries will fail.

      相关文章:

      关于

      生于古城長安,求學金陵,輾轉赴美深造,現漂泊於長安與北京。

      http://www.yenching.org