Search for Strings

cmina

New member
Local time
Today, 16:13
Joined
Mar 21, 2001
Messages
9
Hello everybody!
If anybody can help me with a small problem I have with a database I would be infinetely obliged to her/him!
Here it is:
I have a database containing customer data. I'm trying to create a search form that will search for a given string and create a report with the matching records.
An example to understand the problem better:
I input on the form the following string "smi". By clicking on a button I want to create a report with all the customer names that contain that string (i.e. that will include Smith, Smithers, Smithsonian, etc) - sort of a search engine.
Up to now I've manage to create something that finds the exact string ONLY. (Using a form, a report and a query).
Anybody can help me with this?
Thank you in advance for your help.

cmina
 
Use :

Like *smi*

This will give you Smith,Hasmi,Yasmine.

HTH
mra
 
Use:

Like "*" & [Search for What?] & "*"
as the criteria

When you run the query it will request the data from you. This makes it more dynamic.

Alternatively you can add an unbound field to the form and use that as the search criteria:

Forms!TheFormName!TheControlName

HTH

Ian
 
Thank you guys. It works flawlessly!
Ian your tip is excellent, thank you very much.

cmina
 
smile.gif
 

Users who are viewing this thread

Back
Top Bottom