Sorting in a Report

J

JudyB

I have just completed my first database and I thought all was well until I
tried to run a report. I designed the database to help me keep track of each
employee's department, job title, length of service in each department and
job, as well as seniority. When I started to run a report, I discovered that
I had not assigned LOP (Line of Progression) numbers to the job titles so
that all the jobs within a particular department would sort from the top job
to the bottom job. I have gone back to the JobTitle table and added a new
column titled LOP and assigned each job title a number. I am lost as to what
I need to do next. Can someone please steer me in the right direction?
 
W

Wayne-I-M

Hi Judy

You can sort the report with the grouping and sorting options - but only on
the fields in the report (you can alway add a hidden field to the details
section and sort on that ??

Or

Base the report on a query and sort that - you can add fields that are not
shown in the report (like your LOP) and still sort the query and the report
ill follow that sorting

Good luck
 
S

Steve Schapel

Judy,

First of all, go to the design view of the query that the report is
based on, and add the new LOP field to the query.

Then, in design view of the report, find the Sorting & Grouping fommand
(in versions prior to Access 2007 you can find it in the View menu), and
enter the LOP field in there.

This assumes you don't actually want the LOP value to be shown on the
report itself. If you do, you can add a textbox to the report in the
appropriate location, bound to the LOP field.
 
S

Steve Schapel

Wayne,

A report will only inherit the sorting of the underlying query if there
is no sorting or grouping defined within the report itself. Even then,
I don't think it's guaranteed. Therefore I think it is always best to
sort at the report level.
 
S

Steve Schapel

Wayne,

Well, you did say do one or the other. :) But we don't know at this
stage whether Judy already has any sorting or grouping in place in the
report.

But anyway, I don't agree. That's the point I was trying to make. I
think you should have said to never try to sort a report's data by
sorting it's underlying query.
 

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