Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Development Tools
 Reporting Services Development
 graph help...

Author  Topic 

jhermiz

3564 Posts

Posted - 2004-11-16 : 10:26:07
Trying to create a graph..but cant really determine where to put what.

Basically the graph has this query:


CREATE PROCEDURE rsp_issues_per_week @ClientID integer
AS
SET NOCOUNT ON

SELECT dbo.Issue.IssueID, dbo.Issue.OpenDate, dbo.Issue.TargetDate, dbo.Issue.ClosedDate,
CASE
WHEN ClosedDate IS NOT NULL THEN 'Closed'
WHEN TargetDate < GetDate() AND ClosedDate IS NULL THEN 'Overdue'
ELSE 'Open'
END
AS Status,
Case WHEN ClosedDate IS NOT NULL Then 1
Else 0
END
AS BClosed,
Case WHEN TargetDate < GetDate() AND ClosedDate IS NULL THEN 1
Else 0
END
AS BOverdue,
CASE WHEN ClosedDate IS NULL And GetDate() < TargetDate THEN 1
Else 0
END
As BOpen
FROM dbo.Issue INNER JOIN dbo.Client ON dbo.Issue.ClientID = dbo.Client.ClientID
WHERE (dbo.Issue.OpenDate >= GETDATE() - 7)
SET NOCOUNT OFF
GO


What I am doing is getting the total number of open / closed / overdue issues within a 7 day work week.

So Im thinking on the "x-axis" I need to store the "day of the week"...not sure how to modify my query to do that...or do I need to modify it.

On the y-axis I am guessing it is the total count of issues for that week...seems simple right? Well I got it in Access but not sure how RS handles this...

What do I place in the "series" fields here area. For drop data fields here I put "BOpen" "BClosed" and "BOverdue" from my query (I hope this is right). These fields just say the number of issues.

In drop category fields I put in "Status"...hopefully that is ok...


Can anyone shed some light? Ill continue tinkering with it.

Jon

jhermiz

3564 Posts

Posted - 2004-11-16 : 11:57:58
Hey got it!

Modified query abit...

Check the capabilities of RS:

http://www.jakrauseinc.com/jhermiz/ipw.pdf

Woohooo
Go to Top of Page
   

- Advertisement -