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

Multiple Pivots Expand / Collapse
Author
Message
Posted Friday, September 06, 2013 2:23 PM
SSC-Enthusiastic

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

Group: General Forum Members
Last Login: Thursday, April 17, 2014 2:07 PM
Points: 169, Visits: 506
I need to display data in a pivot style for all 12 months for each of the company's that match a criteria .
so the output will be:

Company 1:

Month 12 month 11 month 10.......
data data data


Company 2:
Month 12 month 11 month 10.......
data data data



Company 3:
Month 12 month 11 month 10.......
data data data




Is there a way to display all the company's with their respective pivots?? How do I design it.
I can do so for one company but not all...


Kindly advise.
Post #1492417
Posted Friday, September 06, 2013 2:46 PM


SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: General Forum Members
Last Login: Friday, April 18, 2014 2:24 PM
Points: 11,990, Visits: 11,007
Without more information than that it is pretty difficult to provide much of a detailed answer...and this question requires a detailed answer.

Please take a few minutes and the read the first article in my signature for best practices when posting questions.


_______________________________________________________________

Need help? Help us help you.

Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.

Need to split a string? Try Jeff Moden's splitter.

Cross Tabs and Pivots, Part 1 – Converting Rows to Columns
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs
Understanding and Using APPLY (Part 1)
Understanding and Using APPLY (Part 2)
Post #1492428
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse