FIND Statement

dragonah

New Member
I am trying to learn Progress on my own and have had some success in doing so. I need help using the FIND statement. I am writing a routine for use with Vantage ERP software, and I want to FIND a record in a table and display it in a field. I have not had any luck doing so. Any ideas out there? Remember, I'm a newbie, so be gentle!

Thanks in advance!
 

ajaysheth

Member
Hi,

You use 'FIND' when you want to find single unique record in a table. For example;

FIND ad_mstr WHERE ad_type = "customer" no-lock no-error.
IF AVAILABLE ad_mstr THEN
DISP ad_mstr.

1. Where ad_mstr is the name of the table and ad_type is the field you are querying.
2. You add "no-lock" to not to lock the table and "no-error to avoid message appearing on screen.
3. If your table as more than one record with ad_type 'customer' then you will get message "More than one ad_mstr records found by a unique FIND. (3166)".

This completes your tutorial on FIND ;-)

HTH.

Rgds,
Ajay.



 
Top