Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9011471
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T02:44:28+00:00 2026-06-16T02:44:28+00:00

While there are many code samples for the individual pieces of this question, as

  • 0

While there are many code samples for the individual pieces of this question, as a neophyte with Report Designer, I cannot get the syntax for this correct.

I have a textfield that I want to display a SUM of “Held Hours” from one of three DataSets, and this is determined by another field in that same DataSet having a value of “H.”

So taking it in pieces, this works to sum ALL hours in ReportDataset.

=Sum((Fields!RegHrs.Value + Fields!OvtHrs.Value),"ReportDataset")

Now, somehow i need to nest that in an IIF. I need that SUM expression to be the “True” return from the IIF when the BillStatus = “H.”

IIF(Fields!BillStatus.Value = "H",true,false)

I cannot seem to figure out how to combine the IIF and the SUM so that they pull from “ReportDataset” and are syntactically correct.

I’ve been trying various permutations of this:

=Sum(IIF(Fields!BillStatus.Value = "H",((Fields!RegHrs.Value + Fields!OvtHrs.Value),"ReportDataset"),0))

Any pointers?


New Info:

The following reports as syntactically correct, but gives me 0 for a return value.

=Sum(IIF(Fields!BillStatus.Value = "H", (Fields!RegHrs.Value + Fields!OvtHrs.Value),0),"ReportDataset")

There should be hundreds of hours returned.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T02:44:30+00:00Added an answer on June 16, 2026 at 2:44 am

    Try a nested sum:

    =Sum(IIF(Fields!BillStatus.Value = "H", Sum(Fields!RegHrs.Value + Fields!OvtHrs.Value,"ReportDataset"),0),"ReportDataset")
    

    Or:

    =IIF(Fields!BillStatus.Value = "H", Sum(Fields!RegHrs.Value + Fields!OvtHrs.Value,"ReportDataset"),0)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This is related to another open question of mine . While there aren't any
While there are many samples around about using OpenGL ES on Android all of
While profiling a bit of code that use's many boost functions with gprof, there
While there are many good online and offline tools for testing regular expressions, I
While there are many guides for Browser Helper Objects, i have a hard time
I'm new at javascript and while there are many more complex solutions, I don't
While I was writing many quasi-identical CSS3 animations , I wondered if there's a
I would like to ask, is there a better way to run this code.
While there are many reasons to use the 'final' keyword in Java , one
There is similar question to this one here but I guess that by this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.