edison1135
Technical User
I’m using Crystal Reports 7 Access database to write a report against an Access database that will calculate earned sales commission. The bonus factor is determined by the instant total of an individual’s cumulative yearly sales. Since each marketing manager has different sales requirements and different assigned bonus factors, the formula is repeated a number of times for the different ranges and factors. I'm also using RunningTotals formulas extensively in this report. A sample of the formula, named BonusFactorAdjusted, I’m using to assign the bonus factor is listed below where @Evaluatesales is the cumulative sales total for Jones:
IF GroupName ({BID_SUBJ.MARKETING_MANAGER})= "JONES" and {@Evaluatesales} >= $1 and {@Evaluatesales} <= $4999 then 0.001
ELSE
IF GroupName ({BID_SUBJ.MARKETING_MANAGER})= "JONES" and {@Evaluatesales} >= $5000 and {@Evaluatesales} <= $9999 then 0.002
To determine the bonus earned for an individual sale, multiply the bonus factor from above by the dollar amount of the individual sale. As the cumulative sales amount crosses a dollar threshold, a different bonus factor will be used. The following formula is an example of determining the bonus
{@BonusFactorAdjusted}*{@Sales}
This approach is working except in the instances where a sale crosses the threshold from one bonus range to the next. As it works now, the entire amount for that sales is multiplied by the higher bonus factor.
What I would like to be able to do is split these amounts that cross a threshold so that both bonus factors could be applied to their respective dollar amounts. Here is an example of how it is working now using Jones' factors from above:
Sale cum total factor bonus
$3000 $3000 .001 $3 (3000 X .001)
$1000 $4000 .001 $1 (1000 X .001)
$2000 $6000 .002 $4 (2000 X .002)
Here is an example of how I would like to be able to split the amounts:
Sale cum total factor bonus
$3000 $3000 .001 3 (3000 X .001)
$1000 $4000 .001 1 (1000 X .001)
$2000 $6000 $ 999 @. 001 = $.999
$1001 @ .002 = $2.002
Thanks,
Edison1135
IF GroupName ({BID_SUBJ.MARKETING_MANAGER})= "JONES" and {@Evaluatesales} >= $1 and {@Evaluatesales} <= $4999 then 0.001
ELSE
IF GroupName ({BID_SUBJ.MARKETING_MANAGER})= "JONES" and {@Evaluatesales} >= $5000 and {@Evaluatesales} <= $9999 then 0.002
To determine the bonus earned for an individual sale, multiply the bonus factor from above by the dollar amount of the individual sale. As the cumulative sales amount crosses a dollar threshold, a different bonus factor will be used. The following formula is an example of determining the bonus
{@BonusFactorAdjusted}*{@Sales}
This approach is working except in the instances where a sale crosses the threshold from one bonus range to the next. As it works now, the entire amount for that sales is multiplied by the higher bonus factor.
What I would like to be able to do is split these amounts that cross a threshold so that both bonus factors could be applied to their respective dollar amounts. Here is an example of how it is working now using Jones' factors from above:
Sale cum total factor bonus
$3000 $3000 .001 $3 (3000 X .001)
$1000 $4000 .001 $1 (1000 X .001)
$2000 $6000 .002 $4 (2000 X .002)
Here is an example of how I would like to be able to split the amounts:
Sale cum total factor bonus
$3000 $3000 .001 3 (3000 X .001)
$1000 $4000 .001 1 (1000 X .001)
$2000 $6000 $ 999 @. 001 = $.999
$1001 @ .002 = $2.002
Thanks,
Edison1135