Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Division By Zero Error Post Reply Post New Topic
Author Message
bullagirl
Newbie
Newbie
Avatar

Joined: 24 Aug 2011
Online Status: Offline
Posts: 12
Quote bullagirl Replybullet Topic: Division By Zero Error
     Posted: 01 Sep 2011 at 5:11am
I have a percentage caluclation formula:
 
I need to somehow preempt the calculation with if review_count=0, then print "N/A" and abort the calculation.
 
Thanks in advance for the help!
~Randi
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 01 Sep 2011 at 5:17am
if Sum ({@review_count})=0 then 'N/A' else
totext((Sum ({@closed_count}) % Sum ({@review_count})),0,"") + "%"


Edited by DBlank - 01 Sep 2011 at 5:17am
IP IP Logged
bullagirl
Newbie
Newbie
Avatar

Joined: 24 Aug 2011
Online Status: Offline
Posts: 12
Quote bullagirl Replybullet Posted: 01 Sep 2011 at 5:36am
You rock! Thanks SO much!! That's two for two you've helped me with.
~Randi
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum