Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Columns as Rows - Crosstab
sageofdata
I have a table of data that stores category hits on each record of data. What I need to do is take the category columns and set them up as rows in a table, With a sum of the category of all the rows within the parameter set.
Like this
Category Hits
Category 1 35
Category 2 37
The data is structured something like this
id Category 1 Category 2
1 0 1
2 1 1
3 0 0
Anyone have any ideas as to the best way to set this up? I need to be able to use the data in a table as well as a chart.
Find more posts tagged with
Comments
mwilliams
Hi sageofdata,
Is there a dynamic number of categories? Or do you know this?
sageofdata
For a particular report the categories would be set, but there will likely be several reports using different sets of categories. So re-usability would be helpful.
I have no problem going in and just setting the categories manually if need be.
mwilliams
Is "hits" the values under each category in the way your data is set up? And you want it summed across all id's for each category?
sageofdata
Yes basically, in the case of the data I am working with, its just a 1 or 0. I need to add up the total across all the rows in the result set.