all groups > sql server reporting services > september 2007 >
You're in the

sql server reporting services

group:

Displaying data in Columns based on Criteria


Displaying data in Columns based on Criteria Charles Allen
9/30/2007 7:20:00 AM
sql server reporting services:
I have data in rows that I want to display in columns based on a value in
each row.

Here's an example of the data:
Employee ID Type Code Amount
123 PAY BONUS 1,000
123 PAY SALARY 5,000
123 DED INS 500
123 DED DENTAL 100
123 DED FLEX 50

Here's how I'd like to display the data:


EMPLOYEE CODE AMOUNT CODE AMOUNT
123 BONUS 1,000 INS 500
123 SALARY 5,000 DENTAL 100
123 FLEX 50

My problem is understanding how to display the items in each column starting
at the top.

Thanks for any help.
--
Charles Allen, MVP
Re: Displaying data in Columns based on Criteria EMartinez
9/30/2007 11:21:28 AM
[quoted text, click to view]


The best way to produce this type of layout is to create a matrix
report where your pivot column (the column that gets split into
multiple columns based on distinct values) is Type. Hope this helps.

Regards,

Enrique Martinez
Sr. Software Consultant
Re: Displaying data in Columns based on Criteria Charles Allen
9/30/2007 9:20:01 PM
I'll give it a shot. Thanks
--
Charles Allen, MVP



[quoted text, click to view]
Re: Displaying data in Columns based on Criteria Venky Dosap
10/1/2007 12:00:00 AM
Please do suggest me on the below requirement in addition to what Charles
Allen has asked for:

How can I add another column that shows the difference between first CODE
column value and second CODE column value?

Thanks in advance!

[quoted text, click to view]

Re: Displaying data in Columns based on Criteria EMartinez
10/1/2007 3:40:06 PM
[quoted text, click to view]


You're welcome. Let me know if I can be of further assistance.

Regards,

Enrique Martinez
Sr. Software Consultant
AddThis Social Bookmark Button