Jan Strube <js(at)deriva(dot)de> writes:
>> is your function stable/immutable, and if so is it decorated as such.
> No, its volatile.
Well, that's your problem. The planner won't push down the IN clause
past the volatile function for fear of changing the query's side-effects.
I'd question whether it's sane to have a view with volatile functions in
it at all. It certainly won't act much like the normal understanding of
a view ...
regards, tom lane