R
Robbie Baquiran
I'm trying to make a query to fetch records from a table based on a
parameter given at run time. It works fine if I only want to run the query
against one value, but how do I enter a parameter so it will several values.
For example if I have a simple table of:
tblExample
| strFirstName | strLastName |
My query would be...
Parameters [valFirstName] value;
select * from tblExample where strFirstName = [valFirstName];
Running the query I would enter "Tom" and it would return all records whose
first name is Tom. If I would like to run the query to return all people
with the first name of Tom and Ted, I couldnt enter "Tom or Ted" because it
would error out.
Any Ideas?
parameter given at run time. It works fine if I only want to run the query
against one value, but how do I enter a parameter so it will several values.
For example if I have a simple table of:
tblExample
| strFirstName | strLastName |
My query would be...
Parameters [valFirstName] value;
select * from tblExample where strFirstName = [valFirstName];
Running the query I would enter "Tom" and it would return all records whose
first name is Tom. If I would like to run the query to return all people
with the first name of Tom and Ted, I couldnt enter "Tom or Ted" because it
would error out.
Any Ideas?