Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Cross-tab % Change

Status
Not open for further replies.

MBalvanz

MIS
Jun 25, 2004
1
US
I have my cross tab grouped by month as the column headings, and I want to calculate a % change from month to month. Is there any way to compare values that are side by side in a cross-tab? Thanks in advance.
 
I think you would have to use a manual crosstab to accomplish this. There are FAQs about how to go about this, but basically you would group on your row field, and then create a series of formulas for your column fields, as in:

//{@Jan} to be placed in the detail section:
if month({table.date}) = 1 then {table.amount}

//{@Feb}:
if month({table.date}) = 2 then {table.amount}

Then you would insert a summary (sum) on each of these formulas and suppress the detail section. Let's say your group is based on {table.ID}. Then to get the change from the previous month, you would create a formula like:

(sum({@Feb},{table.ID})-sum({@Jan},{table.ID})) %
sum({@Jan},{table.ID})

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top