Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
mjimenezh
Yak Posting Veteran
81 Posts |
Posted - 2014-09-24 : 14:55:53
|
Hi to all, I have a sql 2008 r2 view that shows me this:Invoice Year Month ItemCode Qty Cost TotalSale 10 2014 01 x1 1 5 10 11 2014 02 x2 2 4 12 I know how to do a Pivot but just with one operation (SUM(Qty)For...)but I don't know if is it possible to do 3 Sums on Pivot instrucion? I need something like this:INVOICE YEAR 01 02 ItemCodeQty 2014 1 2 x1Cost 2014 5 4 x1Sold 2014 10 12 x1 |
|
|
|
|