Hi

Currently the inspectdb command doesn't take the database indexes into 
account (Ticket - #27060 
<https://code.djangoproject.com/ticket/27060#ticket>). While working on 
adding this feature, there was some confusion related to the inclusion of 
the index type.


I have implemented this feature here 
<https://github.com/django/django/pull/7083> but since Django doesn't 
support introspection of the type of index, currently the generated models 
have the default (B-tree) index no matter what the type of the actual index 
in the database may be. So I would like seek some advice on whether it 
would be a good idea to move ahead with this approach with a comment at the 
beginning of the generated file with the other comments 
<https://github.com/django/django/blob/19e20a2a3f763388bba9263d56db34012e90cf5b/django/core/management/commands/inspectdb.py#L48>
 and 
integrate this basic implementation into Django (with an update on the 
ticket and keeping the ticket open, maybe?).

Or should this be kept on a hold until Django supports introspection of the 
index type for it's backends (PostgreSQL has this feature with some concerns 
about the design 
<https://github.com/django/django/pull/7046#discussion-diff-74431956>) and 
be done correctly all at once. Once that happens we would either use the 
correct index type if it is supported by Django, else add a comment 
informing that the index type is not a match and should be created manually.


Please let me know if any other clarification is required on this. Thanks 
for any help.

Regards
akki

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/28795bda-263b-4d6b-9c04-b5790adba868%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to