Code:
select rtrim(PARTNUMBER) as [Part Number]
, sum(QSHIP) as [Qty]
from WO_LINE
where PARTNUMBER = '334S609'
and ADDED_DTE > DATEADD(M, -12, getdate())
group by PARTNUMBER, QSHIP
Result:
Part Number Qty
334S609 5.000000000
334S609 2.000000000
334S609 18.000000000
How do I get this to return one line with 25 as the Qty?