Check that you are actually using the django.contrib.gis.db.backends.postgis (or other) database backend in your settings.py. It sounds like the SQL to create geometry columns is never getting called.
On Thu, Jan 12, 2012 at 4:38 AM, Vicky .. <vicky.pydevelo...@gmail.com>wrote: > Hi Everyone .. > > I am following the steps given in > https://docs.djangoproject.com/en/dev/ref/contrib/gis/tutorial/# > > and the steps i followed before > https://docs.djangoproject.com/en/dev/ref/contrib/gis/tutorial/#spatial-queries > were > working fine but after that I got error in the ** qs = > WorldBorder.objects.filter(mpoly__contains=pnt_wkt)* in this Statement . > > Error it is showing is > > *FieldError: Cannot resolve keyword 'mpoly' into field. Choices are: > area, fips, geom, id, iso2, iso3, lat, lon, name, pop2005, region, > subregion, un* > > and if I am executing this line > > * sm = WorldBorder.objects.get(name='San Marino')** * > > *Error is * > > ***DatabaseError: column world_worldborder.geom does not exist LINE 1: > ...ld_worldborder"."lon", "world_worldborder"."lat", "world_wor...** > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To post to this group, send email to django-users@googlegroups.com. > To unsubscribe from this group, send email to > django-users+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/django-users?hl=en. > -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.