The SUM statement is used exactly as you might expect, to sum related values. It is used as a sub-function fo the SELECT statement as follows:-
SELECT SUM (Balance) AS TOTAL
FROM sec A_Bal;
This will return a TOTAL of 1100.81as the outstanding balance of all customers in secA_Bal.
SELECT SUM (Balance) AS TOTAL
FROM sec A_Bal;
This will return a TOTAL of 1100.81as the outstanding balance of all customers in secA_Bal.