Django’s ORM supports querying from a specific database (when multiple are defined in your project) via the .using() function for filter-based operations.
e.g. MyModel.objects.filter(name='Bob').using('my_non_default_database')
How would you do the equivalent when creating new records, via the class MyModel() or shortcut like get_or_create()?
usingis a method on theMyModel.objectsmanager, so you can doIf you have a MyModel instance, you can use the using keyword to specify the database to save to. The django docs point out some gotchas.