PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
  • Example: Finding and deleting the customers with a given name
HBuildKeyValue (Example)
Example: Finding and deleting the customers with a given name
WindowsHFSQLHFSQL Client/ServerHyper File 5.5OLE DB
The following code is used to build the value of the composite key from a specific first name and last name. An exact-match search performed in the Customer file is used to delete all the customers with a given last name and first name.
The record is deleted directly (it is not read).
// Build the value of the composite key
sSoughtVal is string = HBuildKeyValue(CUSTOMER, LASTNAME_FIRSTNAME, sLastName, sFirstName)
// Find the record
HSeekFirst(CUSTOMER, LASTNAME_FIRSTNAME, sSoughtVal)
WHILE HFound(CUSTOMER) = True
// Deletion
HDelete(CUSTOMER)
HNext(CUSTOMER, LASTNAME_FIRSTNAME)
END
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment