Sum IIf Statement Values on form

L

Levans digital

I have the following expression in a field (CAlLBS) for each record on a
continuous form;
=Nz(IIf(([Pounds]>=[Cubicfeet]*50) Or ([cubicfeet] Is Null),[pounds]),0)

The above works excellent, However I am having problems summing the values
of the (CAlLBS) field using the following =Sum([CalLBS]).

I dont want to store the values in a query being the query has over 200
calculated fields. The query is linked to a SQL Sever via ODBC driver.

Thanks
 
B

BruceM

Try summing the expression rather than the calculated field:
=Sum(Nz(IIf(([Pounds]>=[Cubicfeet]*50) Or ([cubicfeet] Is
Null),[pounds]),0))

I'm not sure what you mean about storing the calculation result in a query,
as a query does not store such results, but rather calculates them on
demand.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top