Joanne,
Ok, what you have done seems correct and logical. But it appears that
your report is based on a Totals query, and therefore the expression you
are using is using values that are the result of aggregate functions
(e.g. Sum). Which is a problem. My suggestion for the next thing to
try... Make another query, based on your existing query, and then put a
calculated field in there...
Good Sold: [Sumofunits ytd]/([Sumofunits ytd]+[Sumofunits oh])
Then base your report on this second level query, and use the [Good
Sold] for sorting.
--
Steve Schapel, Microsoft Access MVP
I'll try to give details an concisely as possible. It's a selling report and
the calculation I'm doing is % of good sold. The calculation is units
sold/(units sold +units in stock). Simple. When I put that as a calculation
in the control of the report it works fine. I think I must be writing the
calculation wrong in the sorting box. I am copying it exactly as it is in
the control and make it the first level of sorting but it doesn't work. I
get the overflow message. I'm putting the name of each component in []. The
exact formula is =[Sumofunits ytd]/([Sumofunits ytd]+[Sumofunits oh]) Is
there a different format I should be using for the expression? I haven't done
too much sorting on expressions so I'm not sure of the format.