enter one parameter, search multiple fields

ebodin

Registered User.
Local time
Yesterday, 18:54
Joined
Apr 25, 2005
Messages
15
I have two fields (Vendor and Manufacturer) -which to a user searching the DB seem very similiar- and I want the user to be able to search and return results that appear in either field with only one input, but still maintain seperate fields.

I've tried prompting the user with:
Like "*" & [enter Vendor or Manufacturer] & "*"
in the Vendor criteria field of the query then referencing that input by putting:
[Vendor]
in the Manufacturer criteria.

This gives me the results where Vendor = Input and where the Manufacturer and Vendor happen to be the same organization.

I guess that I don't know how to reference the prompted input again. I've searched the forum and haven't found any references to this. Any ideas on how to do this?

thanks,
ebodin
 
In one of the menu options, I think it's Query, you can define parameters.

Define your parameter: [enter Vendor or Manufacturer] and then enter the type as Text or String - whatever the option is.

You can now use [enter Vendor or Manufacturer] multiple times in your query and it will only prompt you once for a value. Remember that since this is an OR selection you should put one instance of [enter Vendor or Manufacturer] per row instead of many on the same row.

i.e.
Code:
[enter Vendor or Manufacturer]
                                          [enter Vendor or Manufacturer]
 
Thanks! That wasn't in the Help files.
 

Users who are viewing this thread

Back
Top Bottom