search two fields in a table

  • Thread starter Thread starter JIM.H.
  • Start date Start date
J

JIM.H.

Hello,
I have a form and it takes an id and a name form the
user. What is the fastest way to search this id and name
combination in a table which has id,name,desc fields and
change desc to "FOUND" and update the table. This
operation should be fast enough since users will be
searching more than one id and name at a time.
Thanks
Jim
 
Hello,
I have a form and it takes an id and a name form the
user. What is the fastest way to search this id and name
combination in a table which has id,name,desc fields and
change desc to "FOUND" and update the table. This
operation should be fast enough since users will be
searching more than one id and name at a time.
Thanks
Jim

An Update query:

UPDATE tablename
SET Desc = "Found"
WHERE id = [Forms]![formname]![txtID]
AND [name] = [Forms]![formname]!txtName];

Execute this query from a command button on the form.
 
Back
Top