Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Browse files

[1.6.x] Fixed #5726 -- Documented that inspectdb doesn't detect defau…


Backport of 15cafaa from master
  • Loading branch information...
commit 75d7bb8d4313f83a832a65cc5e9b17b8ccf97fd1 1 parent 955fdc8
@timgraham timgraham authored
Showing with 5 additions and 0 deletions.
  1. +5 −0 docs/ref/django-admin.txt
5 docs/ref/django-admin.txt
@@ -314,6 +314,11 @@ needed.
``inspectdb`` works with PostgreSQL, MySQL and SQLite. Foreign-key detection
only works in PostgreSQL and with certain types of MySQL tables.
+Django doesn't create database defaults when a
+:attr:`~django.db.models.Field.default` is specified on a model field.
+Similarly, database defaults aren't translated to model field defaults or
+detected in any fashion by ``inspectdb``.
By default, ``inspectdb`` creates unmanaged models. That is, ``managed = False``
in the model's ``Meta`` class tells Django not to manage each table's creation
and deletion. If you do want to allow Django to manage the table's lifecycle,

0 comments on commit 75d7bb8

Please sign in to comment.
Something went wrong with that request. Please try again.