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.
Author |
Topic |
dmaxj
Posting Yak Master
174 Posts |
Posted - 2011-01-18 : 16:44:13
|
I have table with 80 columns. Each of the columns contain values from 1-5. Is there a way to output the count of each value for each column?Something like:Q1 1 - 4Q1 2 - 7Q1 3 - 1Q1 4 - 10Q1 5 - 6Q2 1 - 3Q2 2 - 0Q3 3 - 8Q4 4 - 5Q5 5 - 2 And so on for the remaining columns...Regards |
|
dmaxj
Posting Yak Master
174 Posts |
Posted - 2011-01-18 : 17:35:26
|
so I have been using:SELECT Q1, COUNT(Q1)FROM tableNameGROUP BY Q1GOSELECT Q2, COUNT(Q2)FROM tableNameGROUP BY Q2GOI would have to repeat this query 78 more times. Is there a better way to get desired result other than 80 queries?Regards |
 |
|
dmaxj
Posting Yak Master
174 Posts |
Posted - 2011-01-19 : 09:25:43
|
So, I have made some progress with Analysis Services. I managed to make a data source and a data source view for my sql server table. I also found something close to what I could use by right-clicking the background and choosing 'Explore Data' - Then I have the choice to choose from Chart. I can then see bar graphs with a count for the columns- this is PERFECT, but I cannot print or export the graphs.IS there a way to print or export the graphs - please help.Thank you in advance. |
 |
|
|
|
|