Discussions
Stay up-to-date with the latest news from NetSuite. You’ll be in the know about how to connect with peers and take your business to new heights at our virtual, in-person, on demand events, and much more.
Now is the time to ask your NetSuite-savvy friends and colleagues to join the NetSuite Support Community! Refer now! Click here to watch and learn more!
Average price formula - ERROR: Possible Divide by Zero
Hi, Im trying to return an average price for each item but Im not sure how to get around the divide by zero error. Im thinking NULLIF needs to be applied but im not sure where. Any advice?
sum(case when {item.custitem_year}='2015' then {amount} else 0 end)/sum(case when {item.custitem_year}='2015' then {quantity} else 0 end)
0