select records where first letter of name begins with an a through

J

JK

I'm trying to create a chart but I have too man names. I want to limit the
query to names that begin with an A through M - then create a separate query
for names that begin with M though Z. That way, I can have two reports that
display the data properlly.

Any idea how I would limit the query data based on the first letter of each
person's name? I also need to incorporate the greater than / less than
restriction.

Thanks,
 
J

Jerry Whittle

SELECT Employees.*
FROM Employees
WHERE Left([LastName],1) Like "[A-N]" ;

SELECT Employees.*
FROM Employees
WHERE Left([LastName],1) Like "[M-Z]" ;
 
J

John Spencer

Use the following expressions in your query as criteria under the name field.

For a to m use
LIKE "[A-M]*"

And for n to z
LIKE "[N-Z]*"

John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County
 

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

Top