Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Percentage Formula Post Reply Post New Topic
Author Message
AmandaH
Newbie
Newbie
Avatar

Joined: 17 Aug 2011
Online Status: Offline
Posts: 7
Quote AmandaH Replybullet Topic: Percentage Formula
    Posted: 09 Oct 2012 at 9:06am

Hello,

I have two dollar amount fields that I would like to get the marginal percentage for. The first field is the DealerPrice (the dollar amount is less than the 2nd field) and the second field is the InsPrice. I used Google to find some answers, but nothing worked. One answer I found is this:
 
{Rpt_Logs_HCPCS_Utilization_By_Dealer_V01;1.InsTotal}/{Rpt_Logs_HCPCS_Utilization_By_Dealer_V01;1.DealerTotal})*100
 
But when entered in to Crystal, I get an error message stating "Division by zero".
 
I'm getting back into this program after a year of being away, so all help is greatly appreciated! I'm thinking it's something pretty simple, I'm just not seeing it lol
 
Thank you!!!
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 09 Oct 2012 at 9:12am
if {Rpt_Logs_HCPCS_Utilization_By_Dealer_V01;1.DealerTotal}=0 then 0 else
{Rpt_Logs_HCPCS_Utilization_By_Dealer_V01;1.InsTotal}%{Rpt_Logs_HCPCS_Utilization_By_Dealer_V01;1.DealerTotal}
IP IP Logged
Post Reply Post New Topic
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



This page was generated in 0.016 seconds.