|
-
Aug 15th, 2000, 12:58 PM
#1
Thread Starter
New Member
For a Crystal Reports crosstab report,
I have a SQL statement joining three tables :
reasons, calltype, models.
In the report, models are the columns;
reasons grouped by calltype are the rows.
I'm counting the number of calls for each reason in each calltype for each model.
My results include those models and reasons that had calls (1 or more). I need the columns (models) and rows (reasons) that did not receive any calls (0) on the report too.
Any ideas? Please help.
The SQL has evolved into the monster below:
select tblCallCategory.Category,
tblCallReasons.Reason,
/*tblCustModels.ModelNum,*/
tblModelCategory.CategoryDescr,
count (*) as Callcount
from (((tblCallReasons
join
tblCustEvents
on tblCustEvents.CallReasonId = tblCallReasons.CallReasonId)
join tblCallCategory
on tblCallReasons.CallCategId = tblCallCategory.CallCategId)
join tblCustModels
on tblCustEvents.CustModelId = tblCustModels.CustModelId)
join tblModels
on tblCustModels.ModelNum = tblModels.ModelNum
full outer join tblModelCategory
on tblModels.ModelCategId = tblModelCategory.ModelCategId
[Edited by jenj on 08-15-2000 at 04:19 PM]
-
Aug 15th, 2000, 01:09 PM
#2
Frenzied Member
What does your Join look like?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|