Solved

Sum if Value is Over Zero

Posted on 2011-02-23
3
418 Views
Last Modified: 2013-11-05
I have a report with the column control source of this:

=IIf([HOURS]-[HoursRemainingDisplay]>0,[HOURS]-[HoursRemainingDisplay],0)

I need to sum that column on my report but only include the values that are over zero in that sum. What would the controlsource field for that be?

(see photo)
Right now where all the zeros displayed in this image are actually are actually storing negative values stored so I don't want them on the sum.


ee-sum.jpg
0
Comment
Question by:gcgcit
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 77

Accepted Solution

by:
peter57r earned 500 total points
ID: 34963809
Just sum the expression.


=sum(IIf([HOURS]-[HoursRemainingDisplay]>0,[HOURS]-[HoursRemainingDisplay],0))

0
 

Author Comment

by:gcgcit
ID: 34963935
peter57r: I tried that but when I run the report I get a pop-up box asking for a parameter value for HoursRemainingDisplay and then the total is 0.00 when as you see by the screenshot it should be 37.15.
0
 

Author Comment

by:gcgcit
ID: 34963944
peter57r: Sorry I was making a mistake on my end that works!!! Thanks!
0

Featured Post

Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

AutoNumbers should increment automatically, without duplicates.  But sometimes something goes wrong, and the next AutoNumber value is a duplicate.  This article shows how to recover from this problem.
The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
Familiarize people with the process of utilizing SQL Server views from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Access…
What’s inside an Access Desktop Database. Will look at the basic interface, Navigation Pane (Database Container), Tables, Queries, Forms, Report, Macro’s, and VBA code.

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question