Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

Query to Summarize

$
0
0

Hi All,

I have a table with detailed records in a table.

For example,

col1 col2 col3 col4 benefit
 
1236  30  Peter Samuel 40.00
1236  30  Peter Samuel 50.00

I want to summarize the single value col1 whose one single records 1236 and sum of the benefit like 90.00

This should be applied for the entire table.  Also, I need all the columns in the result set.

Any help!!!

Regards,
kccrga


Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>