Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 887
  • Last Modified:

Division by zero

Hi All!

I continue to get a division by zero error even though the syntax check says "no errors".  I've been starting at it and just can't seem to find out how to fix this issue:

Here is the formula:

If (Previous({Draw_Information.Net Sales Total})-{Draw_Information.Net Sales Total})=0
then 0
else ({Draw_Information.Net Sales Total})/{Draw_Information.Net Sales Total}-(Previous({Draw_Information.Net Sales Total}))*100

spudmcc
0
spudmcc
Asked:
spudmcc
  • 2
1 Solution
 
spudmccAuthor Commented:
Sorry--pasted wrong formula

If (Previous({Draw_Information.Net Sales Total})-{Draw_Information.Net Sales Total})=0
then 0
else ((Previous({Draw_Information.Net Sales Total})-{Draw_Information.Net Sales Total})/{Draw_Information.Net Sales Total})*100
0
 
JayConverseCommented:
You should be checking the denominator:

If ({Draw_Information.Net Sales Total})=0
then 0
else ((Previous({Draw_Information.Net Sales Total})-{Draw_Information.Net Sales Total})/{Draw_Information.Net Sales Total})*100
0
 
spudmccAuthor Commented:
Thank you so much for the 2nd set of eyes.  It was driving me crazy.  I so very much appreciate your quick response, knowledge and time.  

spudmcc (Andy)
0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now