#35136: Interoperability with intarray PostgreSQL extension
-------------------------------------+-------------------------------------
               Reporter:  Jan Hamal  |          Owner:  (none)
  Dvořák                             |
                   Type:  New        |         Status:  new
  feature                            |
              Component:             |        Version:  dev
  contrib.postgres                   |       Keywords:  postgresql,
               Severity:  Normal     |  intarray
           Triage Stage:             |      Has patch:  1
  Unreviewed                         |
    Needs documentation:  0          |    Needs tests:  0
Patch needs improvement:  0          |  Easy pickings:  0
                  UI/UX:  0          |
-------------------------------------+-------------------------------------
 `django.contrib.postgres.lookups` makes use of bare `&&`, `<@` and `@>`
 operators. The `intarray` extension defines it's own set of these
 operators specific to `int4[]`. When using `__overlap` and such on a
 column with `int2[]`, PostgreSQL does not know what operator to use
 (cannot decide between casting to int4[] and using the generic version)
 and fails with "operator is not unique" error.

 This ambiguity could be resolved by using `OPERATOR(pg_catalog.&&)` and
 such instead of bare `&&` within the `django.contrib.postgres.lookups`
 module.

 We have locally worked around the issue by changing the operators upon
 startup, but we are not very comfortable with live-patching Django classes
 as a long-term solution.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/35136>
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018d36dae82a-fb862c52-52cf-4c6d-b4ec-a0e09f769e6f-000000%40eu-central-1.amazonses.com.

Reply via email to