Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Need formula for on time shipping % Post Reply Post New Topic
Author Message
bigmax098
Newbie
Newbie


Joined: 08 May 2008
Location: United Kingdom
Online Status: Offline
Posts: 14
Quote bigmax098 Replybullet Topic: Need formula for on time shipping %
     Posted: 24 Oct 2008 at 9:54am
Hello,

I have attached a picture of the report so far. Basically It is a shipping performance report. Those in red were late, black were on time and green were early. I have the average of these shown in days early/late, but I really want to figure out a formula that will show this in a percentage. Any ideas?

Basically, for the attached image, the "on time" percentage would be 60%. There are 2 early, one on time and 2 late shipments. So, the formula is just 3/5=.6. I just don't know how to make this work in the report. any help would be greatly appreciated! Thanks.

IP IP Logged
JohnT
Groupie
Groupie
Avatar

Joined: 20 Jan 2008
Online Status: Offline
Posts: 92
Quote JohnT Replybullet Posted: 24 Oct 2008 at 1:28pm
You might try using running totals.  Create a running total called countearly.  Summarize your order number and do a count.  Under evaluation, use a formula and put the formula that determines if the order is early.    Repeat this process for ontime and late. 
 
To calculate the early percent, create a formula:
(countearly / (countearly + countontime + countlate)) * 100
 
The ontime percent would be:
(countontime / (countearly + countontime + countlate)) * 100
 
The late percent would be
(countlate / (countearly + countontime + countlate) )* 100
 
I think this should work.  To save some time, I would create one of the running totals and print it on the report to make sure it works.  If it looks good, create the others and the percents.
 
Good luck.
 
IP IP Logged
bigmax098
Newbie
Newbie


Joined: 08 May 2008
Location: United Kingdom
Online Status: Offline
Posts: 14
Quote bigmax098 Replybullet Posted: 27 Oct 2008 at 6:08am
Sounds good...i will give it a try today. Thanks a lot for your help!
IP IP Logged
bigmax098
Newbie
Newbie


Joined: 08 May 2008
Location: United Kingdom
Online Status: Offline
Posts: 14
Quote bigmax098 Replybullet Posted: 27 Oct 2008 at 1:52pm
It worked great, thanks again!
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