question

PhilS-6684 avatar image
0 Votes"
PhilS-6684 asked thedbguy commented

Access (Version 2103) Wildcard Behaviour

Hi all

Right newbie question here...

I have a field in a table which holds drawing numbers of the form 010-04-019-00.
The data-type due to the hyphens is short text.
I have a query with criteria =[Enter Drawing Number].
If I input the entire number when running the query, the record is returned.
If I input part of the number and * I get nothing.

Conversely, change the criteria to Like[Enter Drawing Number].
Input the known drawing number and nothing is found.
Input an asterisk and all results are shown.

An I missing something or using the wrong wildcard perhaps??

Thanks

Phil

office-access-dev
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

thedbguy avatar image
1 Vote"
thedbguy answered

Hi. What do you get if you use this criteria?

 Like "*" & [Enter Drawing Number] & "*"
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

PhilS-6684 avatar image
0 Votes"
PhilS-6684 answered thedbguy commented

Thanks DBGuy

That works, but I'm not sure why manual entry of the * character doesn't.

Phil

· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi Phil. Glad to hear it worked for you. I think it has something to do with how user input is interpreted as a literal string rather than a special character.

Good luck with your project.

0 Votes 0 ·