You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With a multiple database setup (and using "default": {} or with the dummy backend to catch programming errors), creating partitioned tables works, but add partitions to it does not.
For example, PostgresSchemaEditor::add_hash_partition uses a naked transaction.atomic() call. As the database to use (using=) is not specified, Django will create a transaction on the default database rather than the target database, and this will fail if no default database is configured. If a default database is configured, the transaction will execute there which is also not good.
The text was updated successfully, but these errors were encountered:
With a multiple database setup (and using "default": {} or with the dummy backend to catch programming errors), creating partitioned tables works, but add partitions to it does not.
For example,
PostgresSchemaEditor::add_hash_partition
uses a nakedtransaction.atomic()
call. As the database to use (using=
) is not specified, Django will create a transaction on the default database rather than the target database, and this will fail if no default database is configured. If a default database is configured, the transaction will execute there which is also not good.The text was updated successfully, but these errors were encountered: