Query Filter by Entering Criteria

  • Thread starter Thread starter Leo
  • Start date Start date
L

Leo

Hi,

How do I limit my query's reults, if i want the user to enter in the
filtering critera.
I know that you can the box-brackets [ ], but what if you only know
part of the filtering field.

For example,
I want to look up Custome: "John Smith"

How do I make the pop-up filter for all Johns or all Smoth? Because if
I enter only John or Smith, the query doesn't show any results.

thanks
 
However this WILL NOT find Smoth when you put in Smith.

That type of matching logic is really pretty complicated. A number of
years back I saw it at work in an application, but have never seen it
done in Access.

What that system did was, create a matching key field that was used
for searches. Part of it involved taking all of the vowels out but it
was definitly more involved than just that.

But that would be a start.

Ron
 
Sounds like you are referring to SoundEx code.

There are variations on Soundex coding, but basically a soundex code creates
a four-character code based on names sounding like the code.

It returns the Initial Letter and a 3 digit encoding.

--
John Spencer
Access MVP 2002-2005, 2007-2008
Center for Health Program Development and Management
University of Maryland Baltimore County
..
 
John,

Now that you said the word, yes, I think that is what it was called.
From my little experience with it, it seemed to work fairly well for
what it was being used for.

But it was definitely more than Like "*" & fieldname & "*"

Ron
 
I was commenting on the response between the original question and my
response.

It suggested using Like "*" & [Enter part of the name] & "*"


And my statement was that this would NOT find Smoth if you entered
Smith"

Yes it would find both smith and smoth if you entered just SM

But it would also find Smuthers and Smallville and Smartson and Nesman
and Jonesman and Onesman, etc.

Ron
 
I find it amazing what I thought I saw.

Hope he finds some use in all our comments and hope he lets us know
what worked if anything.

Ron
 
Hey Ron,

That was a typo on my end. I meant to ask only for all "John" or all
"Smith". Not Smoth.

sorry about that,

thanks guys!
leo
 
Back
Top