Here I have Submitted a Query For Month Wise GRPO QTY from Vendor.I need Month Wise PO qty Also Along with GRPO qty.
Kindly Help For This?
SELECT CardName,[ItemCode],[ItemName],  as Apr,  as May,  as Jun,  as Jul,  as Aug,  as Sep,  as Oct,  as Nov,  as Dec,  as Jan,  as Feb,  as Mar
( select CardName,T0.[ItemCode],T2.[ItemName],sum(T0.[Quantity]) as Quantity, month(T1.[DocDate]) as Month FROM PDN1 T0 INNER JOIN OPDN T1 ON T0.DocEntry = T1.DocEntry INNER JOIN OITM T2 ON T0.ItemCode = T2.ItemCode and (T1.[DocDate] between '2014/04/01' and '2015/03/31') WHERE (T0.ItemCode LIKE '%%[%0]%%' OR '[%0]' = ' ')
GROUP BY CardName,T0.[ItemCode],T2.[ItemName],T1.DocDate)S
(sum(Quantity) FOR Month IN (,,,,,,,,,,,)) P