Subject Re: [IBO] ib_query ignores my data!
Author Jason Wharton
Paul,

> Just come across a little problem with ib_query.
>
> I have a char(1) field which sometimes contains a letter and
> sometimes a space - IB_query.Fieldbyname('myfield').asstring
> interprets a space as blank :-(
>
> Length(IB_query.Fieldbyname('myfield').asstring)=0

Here's what I would like to do here. I want to make it so that by default
there is no trimming of spaces when the SQLLen of the text column is only 1.
If it is more than one character long then I will allow it to use the
existing default. This will solve your problem and I think behave in a
manner that is more expected.

Does anyone object to this shift in behavior? In short, is the default mode
of trimming spaces on the right appropriate for CHAR( 1 ) columns? Should it
be for VARCHAR columns too or just CHAR?

> no column attributes, no field properties, all default query
> properties except connection and sql. V3.6A
> Could really do with a quick fix/work around.

Sorry this wasn't so quick.

I do hope that you set the FieldsTrimming to NONE since it defaults to
RIGHT. This would have fixed it.

Thanks,
Jason Wharton
CPS - Mesa AZ
http://www.ibobjects.com