Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

group on a field but sort on different field

Status
Not open for further replies.

heathlovell

IS-IT--Management
Oct 26, 2002
36
US
Hello,
I have created a wage report that groups attendence records based on employeeID (autonumber). (I did this since I have several employees with the same last name.) Everything works other than I would like to sort the groups based on the lastname field rather than the employeeID field. Thanks for the help.

Heath
 
Hello Heath,

I'm an amateur, but I'll try to help. The answer depends on how you've created the report.

If your report is based on a table, I don't think you can sort it. However, if your report is based on a query or the Record Source is a query (or SQL statement), you can simply include the lastname field in the query and set the sorting in the "sort row" of the lastname column thing.

If you need clarification, etc. let me know.

Best,

AveenoBoy
 
I didn't have any luck with this. Access wants to group and sort based on employee number. I have tried to delete ascending from the grouping and sorting properties window, but access will not let me. Any other ideas?
Thanks,
Heath
 
You can group and sort if your report is based on a table.

In the sorting and grouping dialog, put the group by which you'd like to sort above the one by which you'd like to group. If you need to also group by the one at top, just repeat it below.

Jeremy =============
Jeremy Wallace
Designing, Developing, and Deploying Access Databases Since 1995

Take a look at the Developer's section of the site for some helpful fundamentals.
 
Jeremy,
Your suggestion worked great. I didn't realize you could move the items up and down in the sort and group dialog. Thanks for the help.
Heath
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top