Opened 7 years ago

Closed 3 years ago

Last modified 3 years ago

#13412 closed New feature (needsinfo)

Exposing multiple db in admin interface is limited

Reported by: idle sign Owned by: nobody
Component: contrib.admin Version: 1.2-beta
Severity: Normal Keywords:
Cc: Triage Stage: Someday/Maybe
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


Suppose I have Django driven site with two applications using two different dbs.

Documentation at gives us an idea of how to expose multiple dbs to admin interface.

However four admin.ModelAdmin methods customized in the example do not handle list_filter option (so query hits the default db, and that rises an exception).

For now I've found only one working solution - using custom manager with overriden get_query_set() method.

Change History (5)

comment:1 Changed 7 years ago by Russell Keith-Magee

Needs documentation: unset
Needs tests: unset
Patch needs improvement: unset
Summary: Exposing multiple db in admin interface is limited (list_filter support)Exposing multiple db in admin interface is limited
Triage Stage: UnreviewedSomeday/Maybe

The documentation says that the admin doesn't have explicit support for multiple databases. Adding explicit support is an area for improvement.

Using routers, it should be possible to use multi-db and the admin for many use cases (in particular, master-slave replication). There will certainly be use cases that admin will have difficulty with.

I'll leave this open as a someday/maybe ticket, given that this is a documented limitation. However, This is something that will need a specific proposal in order to go further.

comment:2 Changed 5 years ago by Julien Phalip

Severity: Normal
Type: New feature

comment:3 Changed 5 years ago by Aymeric Augustin

UI/UX: unset

Change UI/UX from NULL to False.

comment:4 Changed 5 years ago by Aymeric Augustin

Easy pickings: unset

Change Easy pickings from NULL to False.

comment:5 Changed 3 years ago by Aymeric Augustin

Resolution: needsinfo
Status: newclosed

This ticket doesn't contain an actionable proposal.

Last edited 3 years ago by Aymeric Augustin (previous) (diff)
Note: See TracTickets for help on using tickets.
Back to Top