Parameter features

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have to create a query that lets the user enter letters with the parameter
feature and display all the book titles that have the letters anywhere in
their name. I can get it to work, but only with the first letters in the
name, can anyone please help! MSN Chat if pgaglioti88
 
You need to use the LIKE operator and the wildcard character * (asterick).
Take a look at the help file for more examples.

Here is a simple example:

Select *
From tblPerson
Where FirstName Like '*ob*'.

This example will find all people who's first name contains the letters
"OB".
As in:
Robert
Roberto
Roberta
Robin
Bob
Bobby
:
etc...

HTH

Rob Mastrostefano


--
FMS Professional Solutions Group
http://www.fmsinc.com/consulting

Software Tools for .NET, SQL Server, Visual Basic & Access
http://www.fmsinc.com
 
You can have it to prompt you for query criteria like --

Like "*" & [Enter search letters] & "*"
 
Man, that worked perfect, I must of tried every combo except for that! I
really appreciate the help guy!

KARL DEWEY said:
You can have it to prompt you for query criteria like --

Like "*" & [Enter search letters] & "*"

RobFMS said:
You need to use the LIKE operator and the wildcard character * (asterick).
Take a look at the help file for more examples.

Here is a simple example:

Select *
From tblPerson
Where FirstName Like '*ob*'.

This example will find all people who's first name contains the letters
"OB".
As in:
Robert
Roberto
Roberta
Robin
Bob
Bobby
:
etc...

HTH

Rob Mastrostefano


--
FMS Professional Solutions Group
http://www.fmsinc.com/consulting

Software Tools for .NET, SQL Server, Visual Basic & Access
http://www.fmsinc.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top