How can I add a field in a join table?

I have this:

class Item(models.Model):
    name = models.CharField(maxlength=32)

class List(models.Model):
    name = models.CharField(maxlength=32)
    items = models.ManyToManyField(Item)

which creates the 'list_items' join table fine, but then how do I put
a field in that same table?

When I try to add something like this:

class List_Items(models.Model):
    quantity = models.IntegerField()

I get errors:

_mysql_exceptions.OperationalError: (1050, "Table 'stuff_list_items'
already exists")

Does Django have join models or the like?


Thanks,


-- 
Greg Donald
http://destiney.com/

--~--~---------~--~----~------------~-------~--~----~
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?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to