Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sort on formula

Status
Not open for further replies.

mcquam

Technical User
Feb 26, 2007
89
GB
I have a main report and 3 subreports. I have used running totals to count records in the subreports and return them to the main report using shared variables. I now want to sort the resulting data on one of the formula fields but I get the error "field cannot be summarized".

I am using CR11 and MSAccess.

My first subreport called "updates" is grouped and linked on fullname. The grouped records are counted by running total and I have created the following formula:
Code:
WhilePrintingRecords;
Shared numbervar countupdates:={#RTotal0}

The main report has the following formula called "showupdates":
Code:
WhilePrintingRecords;
Shared numbervar countupdates;
countupdates

How do I sort on this field?
 
Crystal can't sort on formulas that establish their values during the WhilePrintingRecords pass.

If you wish to sort the report on such a value, be sure to return it in the result set by using a View or a command as the data source.

- Ido

view, e-mail, export, burst, distribute, and schedule Crystal Reports.
 
Can you explain what you mean please. Is there another approach I should take to achieve the result I am looking for?
 
You can read more detail about this in the Online Help chapter on "Report Processing Model".

Again, your alternative is to return the values you wish to sort on in the result set by using a View or a command as the data source.

- Ido

view, e-mail, export, burst, distribute, and schedule Crystal Reports.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top