Jump to content
  • 0

Calculate A Percentage




I am working with a report and aggregate functions.


I am trying to get a percentage toward a goal.


((COUNT_NON_BLANK [@tblActionLog_ActionCompletionDT]) / (MIN [@pUser_QFGoalWeek]))

Should result in a percentage for completed QuotesFinished to QuotesFinishedPerWeekGoal, but it results in zero.


For diagnostic purposes I've checked the following formulas...


COUNT_NON_BLANK [@tblActionLog_ActionCompletionDT] = 2 (correct)


(MIN [@pUser_QFGoalWeek])) = 10 (correct)


((MIN [@pUser_QFGoalWeek]) / (COUNT_NON_BLANK [@tblActionLog_ActionCompletionDT])) = 500.00% (correct)


((COUNT_NON_BLANK [@tblActionLog_ActionCompletionDT]) / (MIN [@pUser_QFGoalWeek])) = 0.00% (incorrect)


Can anyone spot what I'm doing wrong?


Thank You!

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

Hello EIQ,


As far as I know, aggregate functions cannot work with several fields. I mean, COUNT_NON_BLANK [@tblActionLog_ActionCompletionDT]) / (MIN [@pUser_QFGoalWeek] is the same as COUNT_NON_BLANK / MIN and this formula is applied to all fields that are added to the right-hand panel.


If I understand correctly, the DataType of your pUser_QFGoalWeek field is Text255 or Integer. If you change the DataType to Number/General, the result should be 500% but note that values of the same field are counted as "non blank".

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...