Financial Report Writer precision issue

jenniferdim

Member
Greetings, List -

Has anyone run into this kind of a problem?

I am creating a custom report that divides expenses by sales revenue to get a percent of sales figure (expense/revenue * 100). However, if the expense is 2 or more digits larger than the revenue, the percentage amount is inaccurate (the larger the number of digits, the more inaccurate). I have tried several approaches (as a row calculation, using a cell override, various edit codes, etc), all to no avail. I get the same imprecise number each time.

I have OneWorld B733.2, SP11.3, AS400 platform.

Any ideas will be appreciated.

Thanks,
Jennifer DiMartino
Trendwest Resorts, Inc.



One World
Release B733.2
SP 11.3
Platform AS400
 
Hi Jennifer,

Try the following:

1.) Use Event Rule Variables for the calculations instead of Report Variables.
2.) Change the sequence for calculation: (expense * 100) / revenue

Example:

Define ER variables based on Math Numeric Data Item e.g.:

frm_Expense
frm_Revenue
frm_Percent

based on MATH10 or MN29D9 data item. Of course, the scope of the variables could be different.

Use the event rule logic:

frm_Expense = RV Expense
frm_Revenue = RV Revenue
frm_Percent = frm_Expense * 100
frm_Percent = frm_Percent / frm_Revenue
RV Percent = frm_Percent

Maybe you can use Data Item based RVs (Report Variables) instead of Numeric RVs and in this case you do not need to use Event Rule Variables. Try this way first.

Please. let us know how does it works for you.

Good luck,
Zoltán


B7332 SP11, ESU 4116422, Intel NT4, SQL 7 SP1
(working with B7321, B7331, XE too)
 
Hi, Zoltan -

I think I understand what you are getting at, but alas, I am doing a row report, which limits what I can do with ERs.

Here's a little more detail:

The section that contains the percentages consists of 12 columns, 10 of which are smart fields (YTD, MTD, or QTR depending on the report), which select data for a specific region and 2 of which are totals columns.

The rows are 2-fold: one set of invisible rows which select the account data to get the amounts for each row, and the other set which are calculation rows used to calculate the percentages using the row amounts. The calculation uses TR variables. I tried using a cell override to see if it made a difference when TC variables are used, but the numbers still came out wrong. I have checked the variable length, and it is 15, which should be large enough.

The only time there is a problem is when the dividend (usually an expense amount) is 3 or more digits larger than the divisor (the revenue amount).

I tried your idea of changing the sequence of the calculation, and still the wrong number comes up.

Any other ideas?

Thanks for responding,
Jennifer DiMartino
Applications Developer
Trendwest Resorts, Inc.

One World
Release B733.2
SP 11.3
Platform AS400
 
Back
Top