Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Calculating Percentage Change Expand / Collapse
Author
Message
Posted Thursday, September 27, 2007 3:03 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Thursday, September 26, 2013 9:50 AM
Points: 100, Visits: 70
Comments posted to this topic are about the item Calculating Percentage Change

Ryan
-----------------
www.quadrus.com
Post #403781
Posted Monday, July 4, 2011 9:28 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Tuesday, July 5, 2011 7:13 PM
Points: 1, Visits: 3
Hi. I am working on a report, using SRSS, where I need to compute for the percentage change for the current fortnight versus the previous fortnight. The date range of the current fortnight is a parameter setting. Thus the previous fortnight is dependent on this current date range. To illustrate:

Current fortnight: June 20, 2011 to July 3, 2011 (parametized)

Item Count
-------------
A 5
B 3
C 11
D 2
E 0


Previous fortnight: June 6, 2011 to June 19, 2011

Item Count
-------------
A 4
B 1
C 13
D 2
E 6

Thus the resulting values I need to see are as follows:

Item % Change
-------------
A 25%
B 200%
C -15.00%
D 0%
E -100%

Can you suggest a script that I can set up/use in SRSS to get the percentage change, one that is similar to the sample function at the start of this discussion? Thanks!

Lirio

Post #1136060
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse