Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I would like to run GeoDjango (Django 1.4) with Postgis 2.0.

Whenever I try to run syncdb I get the following error for geographic fields:

Failed to install index for stores.Store model: 
operator class "gist_geometry_ops" does not exist for access method "gist"

I have found various online discussions about this, but no clear answers.

It sounds as though I need to create some indexes by hand... or perhaps there is a patch that can help, but I don't know how to add it.

Please could someone explain simply how to fix this error?

share|improve this question

1 Answer 1

up vote 7 down vote accepted

GeoDjango 1.4 supports PostGIS 2.0 with too many workarounds to make it worth it.

Instead, install GeoDjango 1.5 beta which natively supports PostGIS 2.0 and switch to the official release next month.

share|improve this answer
1  
Thank you! This advice saved me hours and hours! –  Richard Dec 3 '12 at 12:15

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.