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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

P&L in Crystal

Status
Not open for further replies.

mgid

Programmer
Oct 2, 2000
87
US
I've set up a P&L statement using Crystal 8 that is based on transactional data. Now I am trying to set up a report based on the same data that compares prior period based on the user's selection. I've had some success getting the data displayed using a crosstab report and grouping by current and prior period. The snag is this: there are no sections in which to display running totals or way to set up named groups which I used in the straight P&L. I was wondering if anyone could give me some direction with this. I think I may have to create another table based on the transactional table in order to prepare the data to be grouped this way? Thanks in advance.
 
You can't do running totals or formulas with a Cross-tab but you can use conditional totals to accoomplish the same thing.

First calculate the ranges for current and prior.

Then create two conditional formulas:

Current
If {date} in LowDate to HiDate then amount else 0

Prior
If {date} in LowDatePrior to HiDatePrior then amount else 0

Each record will only print in one column or the other, but now you can select two years of data for the report and group the report like your original. Ken Hamady
Crystal Reports Training and a
Quick Reference Guide to VB/Crystal
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top