SQL server Pivot Table issue -
I have a table with columns and prices:
Records status CustName amount blocked 71 Customer_1 132171 11 Booked Customers_1 19974 3 Canceled Customer_1 3900
I want to write a query to get the data:
blocked the customname blocked Gone_card bookmark_recked_mount_mount canceled_how to cancel_account customer_1 71 132171 11 19974 3 3900
related to the problem SQL Server 2008 R2
Should the query actually be?
How to do this:
r1.c, r1 [[Canceled], R2. [Blocked], r1. For Maximum (R) ([Blocked], [Booked], [Canceled])) P) To join R1 (Choose from * Select (Select from A, C, S) T Pete (Max. (A)) ([blocked], [booked], [canceled])) r1.c = r2.c on r2.c
here is Bela
Comments
Post a Comment