#36800: Issue with ManyToManyField renaming
-------------------------------------+-------------------------------------
     Reporter:  Josik                |                    Owner:  Clifford
                                     |  Gama
         Type:  Bug                  |                   Status:  assigned
    Component:  Database layer       |                  Version:  6.0
  (models, ORM)                      |
     Severity:  Release blocker      |               Resolution:
     Keywords:                       |             Triage Stage:  Accepted
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Comment (by ericmuijs):

 I think I'm also having the same issue. I had a many to many field and a
 test fixture. With django 6 im unable to load the fixture: error is that
 the table does not exists. Difference in naming is the cause:

 Naming of many to many table
 1. Dev Database (tables created by django 5) :
 base_vergunningproductgroep_producten (plural)
 2. Test database (tables created by django 6) :
 base_vergunningproductgroep_product

 {{{#!div style="font-size: 80%"
 Code highlighting:
   {{{#!python
   class VergunningProductGroep(TenantModel):
     vergunning = models.ForeignKey(Vergunning, on_delete=models.CASCADE,
 related_name='vergunningproducten')
     producten = models.ManyToManyField(Product,
 related_name='vergunningproductgroepen')
   }}}
 }}}
-- 
Ticket URL: <https://code.djangoproject.com/ticket/36800#comment:4>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/django-updates/0107019b22944eb0-a0fac67d-ea3e-4ff3-8921-3f5af62086ea-000000%40eu-central-1.amazonses.com.

Reply via email to