#28077: GinIndex() and operator class
-------------------------------------+-------------------------------------
Reporter: IzyJeepee | Owner: (none)
Type: New | Status: new
feature |
Component: | Version: 1.11
contrib.postgres | Keywords: postgres, gin,
Severity: Normal | operator, class
Triage Stage: | Has patch: 0
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
Hello,
I want use the GinIndex method to create a gin index with the django's
migration. But while the migration, I have this errror :
{{{
django.db.utils.ProgrammingError : data type character varying has no
default operator class for access method "gin"
HINT : You must specify an operator class ofr the index or define a
default operator class for the data type.
}}}
This error may be resolved by enabling the btree_gin extension.
It is possible to pass the operator class during the index's creation ?
For example :
{{{
class Meta:
indexes = [
GinIndex(fields=['my_field'], name='my_index_gin',
operator_class='my_operator')
]
}}}
Thanks
--
Ticket URL: <https://code.djangoproject.com/ticket/28077>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" 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].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/052.5e57364dbe3571485eb9c218952d76da%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.