ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / Managing databases / HFSQL / HFSQL functions
  • Example 1: Performing an exact-match search for users
  • Example 2: Performing a search on a composite key
HReadSeekFirst (Example)
Example 1: Performing an exact-match search for users
HFSQL ClassicHFSQL Client/ServerStored proceduresNative Connectors (Native Accesses)
The "Customer" file is browsed according to the "NAME" key, for the value contained in the sName variable.
HReadSeekFirst(Customer, Name, sName)
IF HFound(Customer) = True THEN
CustomerFound()
ELSE
UnknownCustomer()
END
Example 2: Performing a search on a composite key
HFSQL ClassicHFSQL Client/ServerStored proceduresNative Connectors (Native Accesses)
This example is used to find and delete all the customers who have a specific last name and a specific first name. The search is performed on a composite key. The record is read.
HReadSeekFirst(CUSTOMER, LASTNAME_FIRSTNAME, [sLastName, sFirstName])
WHILE HFound(CUSTOMER) = True
HDelete(CUSTOMER)
HReadNext(CUSTOMER)
END
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/26/2022

Send a report | Local help