[gdal-dev] DBF indexing?
Smith, Michael ERDC-CRREL-NH
Michael.Smith at usace.army.mil
Wed Apr 25 20:53:16 EDT 2012
Some OGR SQL drivers support creating of attribute indexes. Currently this
includes the Shapefile driver. An index accelerates very simple attribute
queries of the form fieldname = value, which is what is used by the JOIN
capability. To create an attribute index on the nation_id field of the
nation table a command like this would be used:
CREATE INDEX ON nation USING nation_id
1. Indexes are not maintained dynamically when new features are added to
or removed from a layer.
2. Very long strings (longer than 256 characters?) cannot currently be
3. To recreate an index it is necessary to drop all indexes on a layer and
then recreate all the indexes.
4. Indexes are not used in any complex queries. Currently the only query
the will accelerate is a simple "field = value" query.
On 4/25/12 8:38 PM, "William Kyngesburye" <woklist at kyngchaos.com> wrote:
>Is it possible to index fields in a DBF, and does GDAL support that for a
>William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
>"Those people who most want to rule people are, ipso-facto, those least
>suited to do it."
>- A rule of the universe, from the HitchHiker's Guide to the Galaxy
>gdal-dev mailing list
>gdal-dev at lists.osgeo.org
More information about the gdal-dev