Like and Wildcards

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

Guest

Good morning,
I'm building a query in Access 2000 to call for a division (text, len 2) and some description parameters that I would like to apply as Like "*parameter1*" and like "*parameter2*", to put in as criteria. I believe I need the asteriks and perhaps quotes, but I am not sure how to put them around [Parameter1:] and [Parameter2].

My criteria in the query is like this so far:

Like [Par #1:] And Like [Par #2:]

What am I doing wrong? Can someone please help me out?

Thanks!
Derek
 
I'm not sure you really want to AND the criteria. Perhaps you need to OR them.

Like "*" & [Par #1:] & "*" Or Like "*" & [Par #2:] & "*"
 
Derek said:
Good morning,
I'm building a query in Access 2000 to call for a division (text, len 2) and some description parameters that I would like to apply as Like "*parameter1*" and like "*parameter2*", to put in as criteria. I believe I need the asteriks and perhaps quotes, but I am not sure how to put them around [Parameter1:] and [Parameter2].

My criteria in the query is like this so far:

Like [Par #1:] And Like [Par #2:]

What am I doing wrong? Can someone please help me out?

Thanks!
Derek

Like "*" & [Par #1:] & "*" And Like "*" & [Par #2:] & "*"
 
Back
Top