Answered by:
SSRS Matrix
Question

I am using Visual Studio 2005 and have encountered some problems writing my matrix report. I want more Rows after the dynamic columns and I do not know how to do this . I also want Row headers on the matrix. Thank you
Thursday, March 31, 2011 8:17 AM
Answers

Hello AllyMars,
I see you have two main issues:
 1. More rows after dynamic columns
 2. row headers on the matrix
Here are some thoughts to get you started.
1. More rows after the dynamic column
 Have you tried simply selecting the whole of the last column, and choosing Insert Column then choosing 'Right'?
 Alternatively, you could try the following: add a rectangle, then add a matrix and then a table to the right of the matrix. you would need to be sure that the rows were aligned in terms of data and appearance. This would give you the dynamic rows (matrix) and then the static rows (table).
2. Row headers on the Matrix
 Again, a rectangle could help. You could add a rectangle and put the headers as text boxes in the rectangle.
 Alternatively, if you add a table at the end, this would incorporate your new headers.
 Alternatively you could change your SQL or dataset to add in new fields? so, select A, B, 'header1' as header1 from Table.
Hope that helps a bit; please let us know how you get on.
Regards,
Jen Stirrup
 Proposed as answer by Jason Tom Thomas Monday, April 4, 2011 12:56 PM
 Marked as answer by allymars Tuesday, April 5, 2011 8:19 AM
Thursday, March 31, 2011 9:09 AM
All replies

Hello AllyMars,
I see you have two main issues:
 1. More rows after dynamic columns
 2. row headers on the matrix
Here are some thoughts to get you started.
1. More rows after the dynamic column
 Have you tried simply selecting the whole of the last column, and choosing Insert Column then choosing 'Right'?
 Alternatively, you could try the following: add a rectangle, then add a matrix and then a table to the right of the matrix. you would need to be sure that the rows were aligned in terms of data and appearance. This would give you the dynamic rows (matrix) and then the static rows (table).
2. Row headers on the Matrix
 Again, a rectangle could help. You could add a rectangle and put the headers as text boxes in the rectangle.
 Alternatively, if you add a table at the end, this would incorporate your new headers.
 Alternatively you could change your SQL or dataset to add in new fields? so, select A, B, 'header1' as header1 from Table.
Hope that helps a bit; please let us know how you get on.
Regards,
Jen Stirrup
 Proposed as answer by Jason Tom Thomas Monday, April 4, 2011 12:56 PM
 Marked as answer by allymars Tuesday, April 5, 2011 8:19 AM
Thursday, March 31, 2011 9:09 AM 
1) If you are using SSRS 2005, I dont think you would be able to add static columns after the dynamic columns. You can either keep on adding static columns or you can use dynamic columns. A way out would be to somehow get the static column also as part of your dynamic column by tweaking your sql query. for eg,
If you want to add a static column called total after the dynamic column month, you could try tweaking the query like below
select Month, Sales from table
union all
select 'Total' as month, sum(Sales) as Sales from table
Now if you use Month, it will display all the months and the total in your columns. (Ofcourse, you would use the SubTotal functionality in SSRS if you needed the Total, but this is just an example).
Another workaround would be to use a table/matrix after the first matrix as Jen said.
If you are using SSRS 2008 onwards, you can use the tablix, and you should be able to insert static columns after the dynamic columns also.
2) Use a textbox and you can place it inside the header part of the matrix, as Jen said.
Cheers,
Jason
P.S. : Please click the 'Mark as Answer' button if a post solves your problem! :)Thursday, March 31, 2011 1:16 PM 
Hi Jen
1. More rows after the dynamic column
I have tried both your your suggestion. The first one did not work, the second will require a lot of work aligning the fields so I think this will work
2. Row headers on the Matrix
This will also require work aligning the textboxes to the rows but it should work
Thanks very much
Monday, April 4, 2011 12:00 PM