Re: Adding an Index to a model with a custom Field.

2018-05-26 Thread Jan Pieter Waagmeester
I just discussed with Markus H here at DjangoCon Europe, apparently he did a presentation last year about this, which reflects some of the thoughts from above: https://speakerdeck.com/markush/to-index-or-not-thats-not-the-question-djangocon-europe-2017?slide=35 -- You received this message bec

Re: Adding an Index to a model with a custom Field.

2017-12-08 Thread Jan Pieter Waagmeester
On Wednesday, 6 December 2017 00:45:09 UTC+1, charettes wrote: > > From what I remember this feature was planned to be used to replace ` > BaseSpatialField` > special handling of `spatial_index` and allow custom fields to define > > This lead me to some DEP drafts on indexes here: - https://git

Adding an Index to a model with a custom Field.

2017-12-05 Thread Jan Pieter Waagmeester
As part of django-modeltrans , I'm trying to add a GinIndex to the model when a custom Field is added. The simplified version of my naive implementation looks like this: from django.contrib.postgres.fields import JSONField from django.contrib.postgre