Peter Eisentraut <[EMAIL PROTECTED]> writes:
> Tom Lane writes:
>> The text does seem to say that it's okay to add trailing blanks to the
>> pattern to produce a match, when the collating sequence is PAD SPACE
>> type (bpchar in our terms).

> I can't find that.

The spec says "without the appending of <space> characters to MCV",
not "without the appending of <space> characters" full stop.  I read
that to imply that it *is* okay to append spaces to the pattern PCV.
But it's not exactly transparently written in any case.

> I'm also quite suspicious about the wording "...and has the same length as
> that substring specifier."

Yeah, me too.  Does that say that space padding isn't allowed?  If so,
why the thrashing-about earlier in the sentence?  In any case, it seems
to allow a locale-dependent case conversion, for instance.


>> In any case, Hiroshi is dead right that LIKE is supposed to perform
>> collating-sequence-dependent comparison,

> As I have answered to Hiroshi, I think that would really be brain-dead.
> It would alienate LIKE from how pattern matching normally operates.

Well, you make some good arguments, but I'd like to see a fairly strong
consensus that we think the SQL definition of LIKE is broken before we
decide to build a lot of superstructure on our definition of LIKE.  So
far I haven't seen many comments on this thread...

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Reply via email to