Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Creating a percent at the end of a report...
Message
From
18/06/2008 14:37:11
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Title:
Creating a percent at the end of a report...
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01325209
Message ID:
01325209
Views:
76
I have a report that totals a group of 7 amounts across the report, then sums all the totals at the bottom. 6 columns total to a category total and the 7th column is a misc. "other". The SQL query that creates the data also creates a "total" column that adds all 7 columns into a total. So I have Colunm1+Column2 + Other etc. = Total. Which when I review the query result it correctly adds all the columns correctly.

What I am trying to do is determine the percent of the total that represents Other/Total at the end of the report. The problem is the percent will not calculate properly for some reason.

I thought maybe what I needed to do was create a variable summing the Other column and also another variable summing the Total column and then take result of these variablesof divide: ie.. other_total / grand_total = (the Percent i'm looking for). But again the division doesn't seem to work to give the correct percentage.

Does anyone know what I might be doing wrong? BTW, the above calculation is occuring in a summary band.

Bob Bartel
Next
Reply
Map
View

Click here to load this message in the networking platform