I get this error: len() of unsized object
while doing nested for loops in the template:
{% for entry in object_list %}
{% for category in entry.categories %}
{{ category.name }}
{% endfor %}
{{ entry.get_absolute_url }}
{% endfor %}
entry.categries is ManyToManyField
If i remove the nested for everything works fine.
I tried to fetch entries with .select_related() and without - no
difference.
Database backend is MySQL 5
Anyone had a problem like this one?
--
Adam Hoscilo
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-users
-~----------~----~----~----~------~----~------~--~---