ankan
11-28-2007, 01:55 AM
How do I make a simple query check to see if an query gives any match.
The background is that I want to do a checkup if a customer is already in the table before the user enter a new one.
As it is now a form popups after the user have entered a name for the new customer. In the popup I list all customer that match.
What I want to do is to not show the popup if there is no match.
I open the popup with DoCmd.OpenForm with filter information.
Is there something like
if currentdb.execute("select * from customers where name LIKE '*" & name & "*') = true then .....
The background is that I want to do a checkup if a customer is already in the table before the user enter a new one.
As it is now a form popups after the user have entered a name for the new customer. In the popup I list all customer that match.
What I want to do is to not show the popup if there is no match.
I open the popup with DoCmd.OpenForm with filter information.
Is there something like
if currentdb.execute("select * from customers where name LIKE '*" & name & "*') = true then .....