Forum Discussion
Transpose Table Without "Transpose" Button in Query Editor
I am looking to create a table or matrix visual with dates as the column values. However, in my query, the dates are the row values. This is important since in my main visual (a line and clustered column chart), I would like to have dates as the column bar values. If I transpose the query, my line and clustered column chart visualization is not possible.
When I try to create a simple table, the dates will only form as rows with each observation a separate column. I would like to transpose this table but I do not know how to. If I use the matrix visual, I am able to assign the dates to columns and add one set of values to appear correctly under those date values. However, when I add another element to values, the matrix expands so both observations are under one date horizontally. I would like for both observation to be under one date but vertically. Adding the elements as rows does not help of course.
This is what my line and clustered column chart looks like:
This is what my table looks like with dates as the rows (there is a vetical scroll down). I would like for the dates to be the columns instead.
Hello Anonymous
Using a Matrix visual, with your dates on the columns, go to Values > Show on rows and turn it on.
Is that what you are wanting to do?
10 Replies
- jdbuchanan71Super User
Hello Anonymous
Using a Matrix visual, with your dates on the columns, go to Values > Show on rows and turn it on.
Is that what you are wanting to do?
- AnonymousNot applicable
Hi jdbuchanan71 I'm not particularly looking for row labels. My issue is that in the matrix visual, I am able to format the dates as columns as in your visual. However, I am only able to show the very first row of values. If I choose another observation to add to "Values," the column for each date seems to split horizontally so two observations are associated with one date. Here is an example of what I get when adding another observation to "Values" in a matrix.
Instead of the "num" and "cl" values being side by side, I would like for them to be stacked on top of each other so "num" and "cl" are separate row entries.
- jdbuchanan71Super User
If you swtich Values to show on rows, does that not work?
- Sonali_SahuFrequent Visitor
Hi, Can you please help me in sorting the monthyear in this matrix ??
- AnonymousNot applicable
Hi Anonymous
Is this something that you're after ?
If so, you select all columns except date column and in query editor goto Unpivot Columns --> select unpivot columns. when you unpivot columns will display like , date, Attribute, Value
Then select date column goto Pivot Column tab in the menu ribbon, select the Value in drop down.
All set!
- AnonymousNot applicable
Hi Anonymous , doing this results in a table where each entry is the same value (4.00). In addition, while this is similar to the layout I would like to have in my table or matrix visual, this is not the format I would like to have my query output in since my line and clustered column chart format relies on the original query form where each row represents a specific date.
- AnonymousNot applicable
To clarify, my main goal is not to reformat the output of my query since my main line and clustered column chart visualization relies on the current query output. The main thing I am trying to accomplish is to simply transpose my table visualization (not my table from my query output).
- jdbuchanan71Super User
I am talking about making the change only in the Matrix visual.
Here is how my sample matrix visual looks with 'Show on rows' off, each value is a new column under the date:
And with 'Show on rows on'. Each value is on a new row.
- salamanderRegular Visitor
Is this toggle option no longer available? I cannot for the life of me figure it out