Re: BUG #14176: Re: BUG #14173: Not using partitions with ANY(ARRAY[...])

From: Francisco Olarte <folarte(at)peoplecall(dot)com>
To: furstenheim(at)gmail(dot)com
Cc: "pgsql-bugs(at)postgresql(dot)org" <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: BUG #14176: Re: BUG #14173: Not using partitions with ANY(ARRAY[...])
Date: 2016-06-03 16:49:38
Message-ID: CA+bJJby9Bo6wkHMvLYhRRBt+iLApTuHCO_-Ljmx8BnZjyu8ncg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Hi:

On Fri, Jun 3, 2016 at 6:14 PM, <furstenheim(at)gmail(dot)com> wrote:

> If the type is an integer then I don't have the problem. However if I use
> char(2) then I have it.

char tends to do this things. Anyway....

.....
> ' Filter: ((mvar)::text = ANY ('{aa}'::text[]))'

Notice the ::text[]?

> Curiously if I use char varying(2) then it works as expected

Maybe because text[] and varchar[] convert and text[] and char(2)[]
not, you could try to use explicit types ( array['aa'::char(2)] ).
I've seen this happen in other contexts when using char ( unqualified
strings are text, text does not convert that well to char the moment
there is something, like an array[], any() or other function calls,
in the middle ).

> PS sorry I cannot find how to answer directly to the mail

There is alway cut&paste for these things.

Francisco Olarte.

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2016-06-03 17:05:57 Re: After upgrade to 9.5 space not being released
Previous Message furstenheim 2016-06-03 16:14:58 BUG #14176: Re: BUG #14173: Not using partitions with ANY(ARRAY[...])