Malik
Malik

Reputation: 347

SSRS - Multiple Groups to display data

We have a SharePoint List with following columns:

Dep	User	Start Date	End Date	Status
D1	U1	03/08/2015	09/08/2015	RED
D1	U1	10/08/2015	16/08/2015	GREEN
D1	U1	17/08/2015	23/08/2015	YELLOW
D1	U1	24/08/2015	30/08/2015	BLUE
D1	U2	03/08/2015	09/08/2015	GREEN
D1	U2	10/08/2015	16/08/2015	GREEN
D1	U2	24/08/2015	30/08/2015	RED
D2	U3	03/08/2015	09/08/2015	YELLOW
D2	U3	24/08/2015	30/08/2015	YELLOW
D2	U4	17/08/2015	23/08/2015	BLUE
D2	U4	24/08/2015	30/08/2015	RED
D3	U5	10/08/2015	16/08/2015	YELLOW
D3	U6	03/08/2015	09/08/2015	BLUE
D3	U6	10/08/2015	16/08/2015	RED
D3	U6	17/08/2015	23/08/2015	BLUE
D3	U6	24/08/2015	30/08/2015	GREEN

We want to create report in following format:

Dep	User	Week 1	Week 2	Week 3	Week 4
D1	U1	RED	GREEN	YELLOW	BLUE
	U2	GREEN	GREEN		RED
D2	U3	YELLOW		YELLOW	
	U4			BLUE	RED
D3
D3	U5		YELLOW		
	U6	BLUE	RED	BLUE	GREEN

What we have come up till now is:

Departments	User 	8/3/2015	8/10/2015 	8/17/2015 	8/24/2015 
D1	        U10	    GREEN			
				                RED	
	        U12	                            RED			
			        YELLOW		
				                BLUE	
					                        GREEN
	        U13	    RED			
			                                             YELLOW

Any idea to bring all status in one row?

Upvotes: 0

Views: 44

Answers (1)

Jonnus
Jonnus

Reputation: 3038

You need to use a Matrix, with two row groups.

  1. Create the matrix, and set the row to be the Dep field.

  2. Right click the row and select Add Group -> Child Group. Set this child group to be the User Name

  3. Set the column headers to be the Start dates

  4. Finally set the Data to be the status.

The final matrix should look as follows

enter image description here

And will give this result when run

enter image description here

I'm sure once you get to this stage you will be able to do some tinkering to label the columns as you want them, or format it differently when required.

Upvotes: 2

Related Questions