Discussions
Join us for complimentary one-day events around the world and step into a future fueled by AI and limitless potential. Explore new breakthroughs, sharpen your skills, and connect with experts who are shaping what’s next. Experience bold keynotes, interactive learning, and connections that span the global NetSuite community. Discover what's next at SuiteConnect Tour 2026.
Formula (Percent) Average is Summerized a Few Points Off
In my summarized search, I have a column that does an average of profit per sale depending on whether all our numbers are in or not.
It looks like this:
Field: Formula (Percent)
Grouping: Average
The formula: CASE WHEN {custbody_origshipcost} IS NOT NULL THEN {custbody_origprofit}/nullif({amount},0) END
|| CASE WHEN {custbody_origshipcost} IS NULL THEN {custbody_profit}/nullif({amount},0) END
When viewing the search in detail, all the percents are correct. When viewing them in summery, they're a few points too high (like, should be 43.215%, is 46.121%)
There are 2 more fields that show me a sum of the amount and sum of the profit (it's also found on a transaction level). The percent field doesn't match the math done with these numbers.