If the underlying table contains a column of date/time data type, YourDate
say, from which you are returning the month and year with
Format([YourDate],"mmmm yyyy") then add columns to the report's underlying
query by putting the following in the 'field' rows of two blank column:
SortYear: Year([YourDate])
SortMonth: Month([YourDate])
and sort the report first on SortYear and Then on SortDate.
If May 2006 etc are the actual values in a column of text data type,
MonthYear say, the add a column to the query:
SortYearMonth: Right([MonthYear]4) & Format(Month("1 " & [MonthYear]),"00")
and sort the report on the SortYearMonth column. Even if d mmmm yyyy is not
your usual long date format its internationally unambiguous so should work
regardless of the regional date settings in use by the system.
When using a query as the RecordSource for a report don't sort the query,
but use the report's internal sorting and grouping mechanism. The ORDER BY
clause of a query will usually be ignored; not invariably as is sometimes
said, but mostly, so can't be relied on to control the sort order of a report.
Ken Sheridan
Stafford, England