django-model-utils. I'm attempting the very basic use of InhertianceManager as described in the docs.
nearby_places = Place.objects.filter(location='here').select_subclasses()
The only difference is that my parent model/class is abstract. Is this still supposed to work?
I am getting errors like
Caught DatabaseError while rendering: (1146, "Table 'proj.ParentModel' doesn't exist")
and
'Options' object has no attribute '_join_cache'
both of which are errors one typically gets when you attempt to do a query on an abstract class.
in my parent model i've defined the manager as follows:
class ParentModel(OrderedModel):
objects = InheritanceManager()
following the link from the docs to Jeff Elmore's blog (aka the author of the InheritanceManager) he describes how InheritanceManager works.
It is quite clear that the parent model/class cannot be abstract.
.... actually i should have figured this out from the code the first time around.....
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With