Re: Sorting Dates

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



On Fri, 18 Apr 2008 10:25:00 -0700, Melinda wrote:

I have looked through all the postings, but don't see one that quite fits
what I am doing, and have failed at all the attempts I have made. I am
sorting Seniority Dates in a total overtime report. When 3 employees have
the same year to date total hours of overtime, I need it to then sort by
seniority, with the most senior person being called in to work first. I
have three employees with 16.4 hours of overtime, and their seniority dates
are 05-13-2000, 06-14-1990, and 06-28-1986. I see that it is sorting on the
month and then the date, but I need the most senior person being listed
first. How do I change my sort?

What is the actual datatype of the Seniority Date field?
Is it Text datatype or is it Date datatype.?
Where are you doing the sorting? In the query or in the Report?

1) The Seniority Date field should be Date datatype (I suspect yours
is Text).
2) Any sorting you do in the query is irrelevant to the sorting in the
report.
To sort the report, use the Report's Sorting and Grouping dialog...
Click on View + Sorting and Grouping.

If the [SeniorityDate] is actually a Date datatype .....
In the Field/Expression column write:
[SeniorityDate]
on the top line.
In the Sort column write
Ascending


If the [SeniorityDate] is actually a Text datatype .....
In the Field/Expression column write:
=CDate([SeniorityDate])
on the top line
In the Sort Column, write
Ascending

The report should now sort according to Seniority.

--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail
.



Relevant Pages

  • Re: Sorting Dates
    ... Sorting in your query is practically worthless. ... and grouping expressions used in your report design view. ... Then below that select the 'seniority ... Your report can't sort on a field that isn't displayed in the report's field ...
    (microsoft.public.access.reports)
  • Re: Sorting Dates
    ... Open your report in design view, click on menu VIEW - Sorting And Grouping. ... Select the overtime hours totals field and Descinding order That is if you ... Then below that select the 'seniority ...
    (microsoft.public.access.reports)
  • Re: Sorting Dates
    ... I believe I have the viewing and sorting correct, but I thought I would post ... Then below that select the 'seniority ... Your report can't sort on a field that isn't displayed in the report's field ...
    (microsoft.public.access.reports)
  • Re: Sorting Dates
    ... I am sorting in the report, ... sorting by a ClassNo, 2nd, Total Hours, and 3rd SeniorityDate. ... seniority, with the most senior person being called in to work first. ... What is the actual datatype of the Seniority Date field? ...
    (microsoft.public.access.reports)
  • Re: Sorting Dates
    ... I wrote the report I have the seniority date coming from tblEmployees, ... souce from the actual report and type descending or something of that sort. ... What is the actual datatype of the Seniority Date field? ...
    (microsoft.public.access.reports)