Changes between Initial Version and Version 1 of Ticket #12810
- Timestamp:
- Feb 7, 2010, 2:55:13 PM (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #12810 – Description
initial v1 4 4 5 5 It is a little bit unclear, cause if db_table is not provided, Django will create table with name based on the name of the model (table that has the ManyToManyField), and field name that contain this ManyToManyField. 6 6 {{{ 7 7 class Product(models.Model): 8 8 color = models.ManyToManyField('ProductColor', null=True, blank=True) … … 14 14 class Meta: 15 15 db_table = 'eshop_product_color' 16 16 }}} 17 17 running syncdb 18 18 after the creation of 'eshop_product' table Django will create 'eshop_product_color' table that holds relation between Product and ProductColor. The table for ProductColor will never create.