0

如果我有这张桌子:

Column1 Column2     Column3 
20          NULL     3/27/2012 
NULL        50      3/27/2012
NULL        40      3/27/2012

我怎样才能把它变成:

Column1 Column2     Column3 
20          90      3/27/2012 

谢谢!

4

1 回答 1

4

试试这个

SELECT SUM(Column1) Column1, SUM(Column2) Column2, Column3
FROM Table1
GROUP BY Column3
于 2012-10-08T13:24:26.493 回答