Is Unpivot (Not Pivot) functionality available in Linq to SQL? How?
I have seen posts which would fetch you pivot results but not unpivot, Need to know if there is any clean way to achieve ? If not the any workaround would do as well ? Execute this to see unpivot results in Management Studio CREATE TABLE [dbo].[Payment]( [PaymentId] [int] NOT NULL, [EmployeeId] [int] NOT NULL, [RegularHours] [decimal](18, 0) NULL, [OvertimeHOurs] [decimal](18, 0) NULL ) ON [PRIMARY] go insert into payment values (1, 1, 40, 10) insert into payment values (1, 2, 20, 0) go select * from payment select * from payment unpivot ([hours] for [paytype] in ([RegularHours],