#33280 closed Bug (invalid)
Migration with django-database-view don't work with multiple databases. — at Version 2
Reported by: | razielvamp666 | Owned by: | nobody |
---|---|---|---|
Component: | Database layer (models, ORM) | Version: | 2.2 |
Severity: | Normal | Keywords: | orm migration |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description (last modified by )
Change History (2)
comment:1 by , 3 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Summary: | [bug] migration don't work with multiple databases (sometimes) → Migration with django-database-view don't work with multiple databases. |
comment:2 by , 3 years ago
Description: | modified (diff) |
---|
Note:
See TracTickets
for help on using tickets.
Thanks for this report. However a lot of things happen outside of Django, you have many 3rd-party packages, a custom
Operation
in migrations, etc. The main issue is that you're using thequery
attribute to generate an SQL which is not recommended, documented, or supported. Moreover, this helper has issues with parameters (see #25705) and doesn't work when thedefault
database is empty (see #25947). I'm not marking this as a duplicate of #25947 as fixing it will not make.query
the recommended way to generate an SQL. I would use a raw SQL in your case.