Re: Some array semantics issues - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Some array semantics issues
Date
Msg-id 15714.1132365373@sss.pgh.pa.us
Whole thread Raw
In response to Re: Some array semantics issues  (Greg Stark <gsstark@mit.edu>)
Responses Re: Some array semantics issues  (Joe Conway <mail@joeconway.com>)
List pgsql-hackers
Greg Stark <gsstark@mit.edu> writes:
> [ this is back up-thread a bit ]
> And changing that would make it harder to test just the contents of the array
> without having to match bounds as well. That is, You couldn't say "list =
> '{1,2}'" to test if the array contained 1,2. You would have to, well, I'm not
> even sure how you would test it actually. Maybe something kludgy like
> "'{}'::int[] || list = '{1,2}'" ?

Given the just-committed changes to avoid having array_push/array_cat
generate non-spec lower bounds unnecessarily, do you still think it's
important to have a variant of array comparison that ignores lower
bounds?

ISTM that ignoring lower bounds is definitely something that violates
the principle of least surprise.  There was an ease-of-use argument
for it before, but now that we changed the other thing I think we don't
need such a kluge.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Grzegorz Jaskiewicz
Date:
Subject: Re: order by, for custom types
Next
From: Bruce Momjian
Date:
Subject: Re: someone working to add merge?