ssrs tablix pivot
Good day, i am new to ssrs, my problem is as follows: i have a table with data that looks like this Memberid Dateworked mem01 2010-05-01 mem01 2010-05-05 mem01 2010-05-15 mem02 2010-05-01 mem02 2010-05-10 mem02 2010-05-20 i need to pivot the data so that it looks like this: Memberid D1 D2 D3 mem01 1 0 1 mem02 1 1 0 I know how to use the tablix control for a basic report but how do i get it to pivot my data? Any help would be greatly appreciated!
May 25th, 2011 3:26am

Hi, Tou can acheive it in query only. Here is an example:: SELECT VendorID, [250] AS Emp1, [251] AS Emp2, [256] AS Emp3, [257] AS Emp4, [260] AS Emp5 FROM ( SELECT PurchaseOrderID, EmployeeID, VendorID FROM Purchasing.PurchaseOrderHeader)p PIVOT ( COUNT (PurchaseOrderID) FOR EmployeeID IN ( [250], [251], [256], [257], [260] ) ) AS pvt ORDER BY pvt.VendorID; Regards, Amey
Free Windows Admin Tool Kit Click here and download it now
May 25th, 2011 4:37am

Hi, Tou can acheive it in query only. Here is an example:: USE AdventureWorks2008R2; GO SELECT VendorID, [250] AS Emp1, [251] AS Emp2, [256] AS Emp3, [257] AS Emp4, [260] AS Emp5 FROM (SELECT PurchaseOrderID, EmployeeID, VendorID FROM Purchasing.PurchaseOrderHeader) p PIVOT ( COUNT (PurchaseOrderID) FOR EmployeeID IN ( [250], [251], [256], [257], [260] ) ) AS pvt ORDER BY pvt.VendorID;
May 25th, 2011 4:40am

Hi, You can achieve this using a Martix control. 1. Row group should be on MemberId column. 2. Column group should be on DateWorked column. 3. In the detail cell place this expression =Sum(IIF(Fields!MemberId.Value IS NOTHING, 0 , 1)) Hope its clear & helpful.... Pavan Kokkula Tata Consultancy Services.
Free Windows Admin Tool Kit Click here and download it now
May 25th, 2011 11:54am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics