Subject Re: [IBO] Right Trimming Again
Author Nando Dessena
Geoff,

<SNIP equality tests>

Very interesting thing, I didn't know it.

> So if you are building an application in which spaces are significant
> BE VERY CAREFUL!

I'd add if you are building an application in which trailing spaces are
significant, you better get another job. ;-)
I have never said that I would base any code on the fact that a trailing
space is there or not, nor that I would search for a record considering
trailing spaces. Just that I don't want anything between my app and the
database server massage the data.

> This lack of trailing space significance to equality tests was news to
> me (probably because I almost never treat trailing spaces as
> significant). Having found this out, I thought that there may be a
> few here that were also unaware of this issue.

That was really instructive, indeed.

> Although you may not agree, to me this adds weight to the argument
> that IBO should default to removing trailing spaces.

You're right, I don't agree <g>.
I have in fact reached the exact opposite conclusion. The database
server lets you store spaces wherever you want (a select * from table
will reveal that), and the fact that a probable *BUG* (since it is not
documented nor expected, I suppose it must be a bug or a very well
hidden "feature") in it lets you select values regardless of the
trailing spaces is not a point in favor of client side trimming, in my
view. Not considering trailing spaces in comparisons is a (possibly bad)
thing, massaging input data is a totally different thing.
But I will live with whatever default Jason chooses to adopt, as I said.
If it wasn't just a default, I would have voiced my opinion somewhat
stronger. MIDAS does trim spaces (and furthermore it does it badly), and
this is a reason why many can't use it.

> It also adds
> weight to the idea that whereever possible you should avoid using
> trailing spaces as significant characters.

I agree completely, in case I have been misunderstood before. Let's try
not to mix topics (even though I can see the differences are quite
subtle); we have several: trailing space significance,
--
____
_/\/ando