Link to home
Start Free TrialLog in
Avatar of smsdesigns
smsdesignsFlag for United States of America

asked on

Need Access 2007 Report to sort ASC

Greetings:

I have created a report in an Access 2007 database. My Report source SQL statement is below. In the attached screenshot, you can see that teh report is a listing of employees by Manager. The Manager field is being fed by the alias shown below. I want the Managers to sort ASC by the Manager's last name. I tried adding ASC to the statement below, with no luck. Any idea what I am doing wrong?

SELECT tbl_Employees.*, tbl_Managers.[Lname] & ", " & tbl_Managers.[Fname] AS MgrName
FROM tbl_Managers INNER JOIN tbl_Employees ON tbl_Managers.ID = tbl_Employees.ManagerID
ORDER BY tbl_Managers.Lname, tbl_Managers.Fname;

reportscreenshot.jpg
ASKER CERTIFIED SOLUTION
Avatar of Dale Fye
Dale Fye
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
you may need to include to your SQL statement the fields LName and FName


SELECT tbl_Employees.*, tbl_Managers.[Lname] & ", " & tbl_Managers.[Fname] AS MgrName, LName,FName
FROM tbl_Managers INNER JOIN tbl_Employees ON tbl_Managers.ID = tbl_Employees.ManagerID
smsdesigns,

Please disregard my post. It's a duplication with other EE's post.

I am sorry fyed and carpricorn1.

Sincerely,

Ed
Happens all the time.  

What I hate is when I start a response when there are no others posted, get sidetracked, and 30 minutes later complete my response and hit send, then see that 3 or 4 others have already posted the same response.