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

Trying to create a manual cross-tab

Status
Not open for further replies.

tigerjade

Programmer
Mar 17, 2004
237
US
I think I'm getting closer on this thing; I've been reading everything I can in this forum about manual cross-tabs, and know that's what I need. Now, I need to figure out how to get the data into the report properly. Please, please, forgive my ignorance.

Crystal Reports 9 Dev Edition
SQL Server 2000
Example data:
6/6/05 13512835 203852035 18241047 203852035 238471087
6/13/05 23850128 235070788 23580810 769654297 239576297

Required result:
6/13/05 6/6/05
Jun 05 23850128 13512835
Jul 05 235070788 203852035
Aug 05 23580810 18241047
Sep 05 769654297 203852035
Oct 05 239576297 238471087

One parameter: EndDate
Previous date is formula StartDate

Grouping by the datetime field
Record select formula: historyDate IN [{?EndDate},{@StartDate}]

If I don't have the selection criteria on there, I get every record grouped very nicely. But if I put in selection criteria, I don't get any data returned; the grouping header is blank, as are the formulas (which are s'posed to show -99 if there's no data there; instead, they're blank on preview too).

Formula to pull data for EndDate column: if (DateDiff("d", {?EndDate},{History.historyDate}) = 0) then month0 else -99
similar for StartDate column formulas

Where do I start fixing this thing?

TIA a million,

tigerjade

"Always code as if the person who ends up maintaining your code will be a violent psychopath who knows where you live." -- Martin Golding


 
oh yeah; the dates in the first column correspond to the different columns in the table: jun05 is month0, jul 05 is month1, etc....

"Always code as if the person who ends up maintaining your code will be a violent psychopath who knows where you live." -- Martin Golding


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top