Expand my Community achievements bar.

The Community Advisors application is now OPEN for the second class of 2024. Apply to become a part of this exclusive program!

Variance between work hours and total hours

Avatar

Level 8
Hey guys.... Can someone see what I am missing here. I am trying to pull the percentage of total project hours (totalHours) against the planned project hours (work), but I cannot get any results. The text looks like this: valueexpression=DIV({totalHours},{work}) valueformat=doubleAsInt I have also tried "compound" for the format and "workRequired" for planned hours, but no dice there. I cannot get SUB or SUM to work with these two data points either. Any ideas on what I am missing? Brandon Pritchard System Administrator iNHouse Marketing - Nationwide pritcb1@nationwide.com
2 Replies

Avatar

Level 8
I can't see a reason why what you've written wouldn't work. However... totalHours is only updated when the project finances are updated - at a minimum overnight. It is a compound object. Actual Hours (actualWorkRequired) should equal totalHours after finances are recalculated, but is always current. {work} is a double, not a compound so you're mixing the field types in the maths. That might have something to do with it, but I'm just guessing. I'd just change the fields you're drawing on to actualWorkRequired and actualWork: valueexpression=DIV({actualWorkRequired},{workRequired}) Barry Buchanan - WMA Work Management Australia

Avatar

Level 8
Got it!! Appreciate the nudge in the right direction. My suspicion was the mismatched formats as well, and I think that was it. I made some modifications and the final expression is: valueexpression=CONCAT(LEFT(PROD(100,(DIV(({actualWorkRequired}/60),({workRequired}/60)))), 4), "%") valueformat=compound This gives me the % of actual hours logged vs. the planned hours on a project. Couple that with a little formatting to highlight when we go over budget on our hours and we got ourselves a legit looking report! ‚òª Full text looks like this if anybody is interested.... descriptionkey=Difference in hours between scoped and logged hours. displayname=Overage styledef.case.0.comparison.icon=false styledef.case.0.comparison.leftmethod=actualWorkRequired styledef.case.0.comparison.lefttext=actualWorkRequired styledef.case.0.comparison.operator=gt styledef.case.0.comparison.operatortype=compound styledef.case.0.comparison.rightmethod=workRequired styledef.case.0.comparison.righttext=FIELD:workRequired styledef.case.0.comparison.trueproperty.0.name=bgcolor styledef.case.0.comparison.trueproperty.0.value=eac6c9 styledef.case.0.comparison.truetext= textmode=true usewidths=true valueexpression=CONCAT(LEFT(PROD(100,(DIV(({actualWorkRequired}/60),({workRequired}/60)))), 4), "%") valueformat=compound width=100 Thanks again! Brandon Pritchard System Administrator iNHouse Marketing - Nationwide pritcb1@nationwide.com