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

How do I make my own cross-tab report w/o using the cross-tab wizard?

Status
Not open for further replies.

mn20

Programmer
Feb 16, 2001
10
SG
i need to create a cross-tab report. the "dates" as the row headers and "names" as the column headers. in each cell, i'll have the number or the count of names that occurred during that date. i can create this using the cross-tab wizard but there are fields that i don't need (ex. the total fields) and there are fields that are lacking. maybe you guys can help me with this. thanks.

maybe you know how to rotate text fields in crystal reports cos i want the text to be writen vertically.
 
You DO need total fields. To get the count of names you want the name field as the total field. Crystal counts any character field used as a total field by default.

To create the cross-tab manually, create any other report and then use Insert - Cross-tab. Place this in the report header or footer to summarize all records in the report.

Rotating text can only be done in V8 of Crystal. Ken Hamady
Crystal Reports Training/Consulting and a
Quick Reference Guide to VB/Crystal (including ADO)
 
Hi mn20

I hope i'm not too late because I've some information that may help.
I've already made some Cross-Tab reports manually,using date as the column headers, written vertically.
( like 01
Mon ).
You just need to play with the Left, Right, Mid and Chr functions ( Chr(13) says to go to the next line.). You insert a Chr(13) after every letter, and that's it.
For the total fields you don't want, just click on suppress in the common tab of the desired field.
 
mn20: I think the other guys have mis-understood your question. Let me see if I've got it?

You need to create the effect of a cross tab using dates as columns and names as rows with a count of the number of times a name appears on a specific date?

To do this without the use of a cross tab at all (whether using the expert or inserting a cross tab object) requires that you create a series of formulae to select the appropriate data. This is something I have done successfully in the past but you have to limit the process to a defined number of columns and you need to restrict the response to data within those defined columns or you will get wrong results. Here's a suggestion

Date1 - If Dow(Date)=1 and Name_Chosen = Name then 1 else 0
Date2 - If Dow(Date)=2 and Name_Chosen = Name then 1 else 0
Date3 - If Dow(Date)=3 and Name_Chosen = Name then 1 else 0
Date4 - If Dow(Date)=4 and Name_Chosen = Name then 1 else 0
Date5 - If Dow(Date)=5 and Name_Chosen = Name then 1 else 0
Date6 - If Dow(Date)=6 and Name_Chosen = Name then 1 else 0
Date7 - If Dow(Date)=7 and Name_Chosen = Name then 1 else 0

Then you'll need Sum formulae for each column resetting for each name and suppress the Details

HTH David C. Monks
david.monks@chase-international.com
Accredited Seagate Enterprise Partner
 
mn20: I overlooked your question re vertical printing. This format option is available in version 8 or there is a UFL available to create the same effect on certain earlier versions. Drop me a line if you need this. David C. Monks
david.monks@chase-international.com
Accredited Seagate Enterprise Partner
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top