Grouping a report on three levels

  • Thread starter Nancy via AccessMonster.com
  • Start date
N

Nancy via AccessMonster.com

I have a report that I want to group by Supervisor, then Operation Number,
then Employee. I have successfully grouped by Supervisor and then Operation
Number but for some reason the Employees aren't in alphabetical order. Under
sorting and grouping I have placed Supervisor first, then Operation Number,
then Employee. I have all three set to sort in ascending order. I also tried
using code in the report's On Open event but kept getting errors. Any ideas
on why I can sort by two levels and not three? Thanks!
 
J

John Spencer

As a guess, your employee field is not showing what is being stored in the
database. Did you use a lookup field for employee in your table. IF so, the
actual value stored is a reference to the information in the employees table
(usually a number).

Try adding the employees table to your query and linking it to your other
table. Once you have done that you should be able to get the field(s) that
really contain the employee name.

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

KARL DEWEY

What order are you getting the employees?
Does it match that of the query?
Is the employee a lookup by chance?
 
A

Armen Stein

As a guess, your employee field is not showing what is being stored in the
database. Did you use a lookup field for employee in your table. IF so, the
actual value stored is a reference to the information in the employees table
(usually a number).

This is almost certainly what's going on.

But on a more obscure note, it's also possible (unlikely, but
possible) that there are one or more leading spaces in the employee
names, especially if they were imported from another system. The
extra spaces are hard to see, so they can cause the ordering to appear
incorrect.

Armen Stein
Microsoft Access MVP
www.JStreetTech.com
 

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