Getnext lookup -
Nancy Palmquist
nlp at vss3.com
Thu Dec 4 11:29:10 PST 2008
Kenneth Brody wrote:
> Quoting Nancy Palmquist (Thu, 04 Dec 2008 11:53:36 -0500):
>
>> Walter Vaughan wrote:
> [...]
>>> ::pn(10,,g)=upd(1):
>>> ::lookup - k=pn i=b -nx:
>>> :1 ne pn:show "@No match for "<pn; goto loopU:
> [...]
>> Remember if 1="BigPart" and pn eq "BIG" it will find that part of no
>> other part name starts with BIG.
>>
>> And you test 1 ne pn would not catch that difference.
>>
>> 1{"~" ne pn{"~" would test true when they are identical and false
>> when they are not.
>>
>> Any silly character that is never in pn would work.
>
> In this particular case, since pn is defined as (10,,g), the above steps
> aren't necessary, as pn won't be "BIG" but rather "BIG ". As such,
> it would not match "BigPart ".
>
> In cases where you don't have a fixed-length field, such as using the
> import's field upd(1) directly, then your advice is correct.
>
That is not supported by my experience with filepro. You would have to set the
environment variable that tells it to match the full field to make sure that
happens and that changed the existing behavior for many people.
I think it is just easier to check.
Also what if he has no record that matches PN - then I think his programming
needs to allow for that possibility and add a record.
Nancy
--
Nancy Palmquist MOS & filePro Training Available
Virtual Software Systems Web Based Training and Consulting
PHONE: (412) 835-9417 Web site: http://www.vss3.com
More information about the Filepro-list
mailing list