Opened 20 years ago

Closed 17 years ago

#523 closed enhancement (invalid)

Delay index creation w/ PostGIS PostgreSQL ogr2ogr driver

Reported by: sfrost@… Owned by: warmerdam
Priority: high Milestone:
Component: OGR_SRS Version: unspecified
Severity: minor Keywords:
Cc:

Description (last modified by hobu)

When loading data into PostgreSQL it takes a great deal longer if an index is
already in place than it takes to load all the data and then generate an index.
 It would be nice to have an option to ogr2ogr to tell it to not create an index
on the table initially so that when doing batch loads the load will go much
faster.  The index/constraint could then be applied at the end of the load
either by the user (probably best, just have to command in the manpage next to
the option to disable it) or by a special call to ogr2ogr.

Change History (2)

comment:1 by warmerdam, 20 years ago

Stephen, 

I have reviewed the existing PostgreSQL/PostGIS driver, and I don't believe it
ever builds the spatial index automatically.  It seems you need to do that
manually after the fact, 


comment:2 by hobu, 17 years ago

Description: modified (diff)
Resolution: invalid
Status: assignedclosed

AFAIK, the PostGIS driver does not create an index upon layer creation, but there is a layer creation option proposed in #959 that might make it in if there is time.

Note: See TracTickets for help on using tickets.