Grouping (1 Viewer)

chastst

Registered User.
Local time
Today, 06:17
Joined
Oct 19, 2000
Messages
17
I have a report based on a query that sorted the results by month. Then, I don't know what changed or if anything changed, but when I attempt to run the report I get this error:

Compile error in query:
 

chastst

Registered User.
Local time
Today, 06:17
Joined
Oct 19, 2000
Messages
17
oops --
continuing;

the error is:

compile error in query expression '(Year(StartDate)*12+Month(StartDate-1)/1.

That is all I can read - there may be more.

If I group the report on Each Value of StartDate, it will run. Any Ideas on what has happened

P.S. I have even re-run the Report Wizard, and the same error occurs.
 
R

Rich

Guest
check that the property sheet for the report does not have the sort order attached to it. Post back if not successful.
 

chastst

Registered User.
Local time
Today, 06:17
Joined
Oct 19, 2000
Messages
17
Haven't found it in there. Still having the same problem even after re-writing the report.
 
R

Rich

Guest
Think it should be Year([TableName].[DateField])*12+DatePart("m",[TableName].[DateField])-1
HTH
 

chastst

Registered User.
Local time
Today, 06:17
Joined
Oct 19, 2000
Messages
17
I wrote this report using the report wizard. If the code is incorrect, where could I find it to tweak on it?

Thanks
 
R

Rich

Guest
Click on the query builder for the report data source I would think it's in there.
 

Users who are viewing this thread

Top Bottom