How Do I Do - Like "*String*" - in DCount Function..?

J

Jado

How Do I Do - Like "*String*" - in Access 97 DCount Function..?

my example (not working)

Dcount "[Tel No]", "Table1","(([Field1]) = 'myItem') AND (([Field2]) Like
'*Sale*'

Thanks

Jado
 
J

John Spencer (MVP)

Add parentheses around the parameters AND make the criteria a string by adding a
closing parentheses.

Dcount ("[Tel No]",
"Table1",
"([Field1] = 'myItem' AND [Field2] Like '*Sale*'")

That should all be on one line, but I broke it up into three lines for visual
clarity
 

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

Similar Threads

Excel - Wich Function should I use? 1
dcount 1
DCount Function and Variable 2
My dcount is not working 3
access report DCount function 4
DCount & DSum 8
Assistance with vbYesNo 3
Dcount function 2

Top