Subject | Re: [IBO] Re: Sending demo of Problem |
---|---|
Author | Helen Borrie |
Post date | 2001-09-27T08:57:59Z |
At 10:58 AM 27-09-01 +0200, you wrote:
Try this:
Update The Field set id = 'FOURTH' where id='FIRST'
and see what you get!
Helen
InterBase Developer Initiative ยท http://www.interbase2000.org
_______________________________________________________
>Helen,Nando:
>
> > > > 2. I set your Keylinks to ID. (Notice that I had a little trouble with this because you made this a char(12) so your unique id values get stored as "FIRST ", "SECOND " and "THIRD " and a query 'where "ID" = 'FIRST' will not find the row...
> > >
> > >According to the SQL standard and how IB implements it, it surely
> > >should.
> >
> > Nando,
> > Test it for yourself. Char fields get right-padded with ascii 32 at creation time.
>
>Sure. So do string constants when a comparison must be made against a
>char field, so that
>
>where ID = 'FIRST'
>
>is actually evaluated as
>
>where ID = 'FIRST '
>
>assuming that ID is a CHAR(12) field.
>I hope I have made it a little clearer now.
>Test it for yourself. ;-)
Try this:
Update The Field set id = 'FOURTH' where id='FIRST'
and see what you get!
Helen
>CiaoAll for Open and Open for All
>--
> ____
>_/\/ando
>
>
>
>
>Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
InterBase Developer Initiative ยท http://www.interbase2000.org
_______________________________________________________