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!

Display the values in vertical

Status
Not open for further replies.

rajrev

Programmer
Sep 25, 2003
148
US
Hi,

I am using Crystal Reprot XI & DB2 database.

The output of the report needs to be in row/column format.
(Cross Tab). But if we use the running total calculation (ie runningtotal1 (minus) runningtotal2) there is no option to put this one in the cross tab.
Is there is any way to solve this problem.

needed as follow.

Asset.Manager: AMan1 (parameter)
Employees under this manager are:
SalesMan1
SalesMan2
SalesMan3
SalesMan4

Need to provide monthly status for each salesman (ie calcuation total sold - total product given to the salesman)
Pl. Consider the total sold and given are 2 running totals

For example: if the salesMan1 sold 10 product on Jan and total given target is 15 then the value in Jan for the salesMan1 is -5...


Output

Asset.Manager: AMan1
Year : 2005

Jan Feb Mar Apr ... Dec
salesMan1 -5 0 -2 -1 ... 0
salesMan2 0 0 0 0 ... 0
salesMan3 0 -1 0 -3 ... -1
salesMan4 -1 0 0 0 ... 0

---------------------------------------

This is an example. Please let me know if you need more infomraiton.


Thanks
RR
 
You could create a manual crosstab by grouping on salesperson, and then creating two running totals and one formula per month. In the evaluation of section of your running totals, you would place:

month({table.date}) = 1 //for January

Reset on change of group (salesperson).

Then your formula would be:

{#Jansold}-{#Jangiven} //etc.

Or you could consider whether you could be using conditional formulas or inserted summaries instead of running totals so that you could use an inserted crosstab.

-LB
 
Thanks. That's what I did. I thought there may be some other way by using array.

Thanks,
RR
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top