| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Grzegorz Grabek <grzegorz(dot)grabek(at)gmail(dot)com> |
| Cc: | pgsql-bugs(at)postgresql(dot)org |
| Subject: | Re: GIN index not working for integer[] if there is more then one column in table |
| Date: | 2017-07-07 17:38:39 |
| Message-ID: | 21098.1499449119@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-bugs |
Grzegorz Grabek <grzegorz(dot)grabek(at)gmail(dot)com> writes:
> I created GIN index on my table as :
> CREATE INDEX my_table_my_column_idx
> ON my_table
> USING GIN((array[mycolumn]);
> Column is integer type.
> It works pefectly fine when i use "array[my_column]=array[50]" for example.
> But when i use diffrent operators @> <@ && it doesnt use index.
I suspect you have the intarray extension installed and it is capturing
your uses of @> and <@. intarray has its own GIN operator class which
will support its operators, but the core GIN operator class for arrays
doesn't know anything about those operators.
> Few examples when it works, and when doesn't.
The first one of these works fine for me in a vanilla installation.
I didn't try the rest ...
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Frank Gard | 2017-07-07 20:49:02 | Re: BUG #14737: Wrong PL/pgSQL behaviour |
| Previous Message | Grzegorz Grabek | 2017-07-07 17:19:42 | GIN index not working for integer[] if there is more then one column in table |