Hi All Crystal experts,
I have a report which has 2 groups, one on month(post_date) and another one on month_number. Now I am showing some aggregate values like sum(invoice_total), sum(Cash_total), sum(Open Item) etc which are sorted and grouped by month(post_date) for each month.
I have one formula in my report that is:
if @invoice_total = 0 then 0 else (@Cash_total) / (@invoice_total). None of my fields shows zero value in result but output of this overall formula is coming zero in the report.
I did like this also,
if @Cash_total= 0 then 0 else (@Cash_total) / (@invoice_total). But output of this formula also shows zero. while both fields have values
Could anybody help me on this. How to resolve this issue?
where are the formulas located on the report.
Most likely, the formula which is using the divide operator is getting evaluated before the @Cash_total and @invoice_total formulas.
This can happen because of the sections where they are placed, for e.g the divide formula being placed in the Group Header whereas,@Cash and @Invoice formulas being used in Group Footer.
Did you get a chance to test the output after putting the code
Evaluateafter (@Cash_total);
Evaluateafter(@invoice_total);
in the formula where the division operation is written?
Prathamesh
Hi Remi,
Please attach the report with saved data if possibe.
-Abhilash
Add a comment