Solved

Sum if Value is Over Zero

Posted on 2011-02-23
3
383 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
  • 2
3 Comments
 
LVL 77

Accepted Solution

by:
peter57r earned 500 total points
Comment Utility
Just sum the expression.


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

0
 

Author Comment

by:gcgcit
Comment Utility
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
Comment Utility
peter57r: Sorry I was making a mistake on my end that works!!! Thanks!
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

In a multiple monitor setup, if you don't want to use AutoCenter to position your popup forms, you have a problem: where will they appear?  Sometimes you may have an additional problem: where the devil did they go?  If you last had a popup form open…
I see at least one EE question a week that pertains to using temporary tables in MS Access.  But surprisingly, I was unable to find a single article devoted solely to this topic. I don’t intend to describe all of the uses of temporary tables in t…
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…
Familiarize people with the process of utilizing SQL Server functions 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 Ac…

728 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now