Re: Check to see if a record exists in a file


[ Follow Ups ] [ Post Followup ] [ Signature.net Forum ]

Posted by Robert G Laurin on May 04, 2009 at 14:26:13:

In Reply to: Re: Check to see if a record exists in a file posted by Stephen Auerbach on May 04, 2009 at 06:39:21:

I can't believe that people still use the READ statement. Using INQUIRE is much more natural and rids of all problems with EXTRACT conditions.

How about:

 Let Found = No
Position (N5) Key=VNBR$,Excpsub=ExcpRet
Do
XKey$ = Key(N5,Excp=NotFound) ! Excp=EOF
If Sub(XKey$,1,5) NE VNBR$ Break ! End of Range
Inquire (N5,1450)
If checkno$ = HCKNBR$ And _
invoice$ = HREFNBR$ And _
chkdate$ = YOURDATE$
Let Found = Yes
Break
Loop
NotFound:
Return



Follow Ups:



Post a Followup

Name:
E-Mail:

Subject:

What is the name of the main Signature System's Product?  

Comments:

Optional Link URL:
Link Title:
Optional Image URL:

You may attach up to 5 files to your followup (see below):





Each file can be a maximum of 1MB in length Uploaded files will be purged from the server on a regular basis.


[ Follow Ups ] [ Post Followup ] [ Signature.net Forum ]