Quote:
Originally Posted by Publisher Bucks
I have a column with sales, for example 5, and another column that has refunds, -2 would the total_amount be 3 when displayed?
|
No, because you have not summed the 2 columns. The code I posted only sums one column.
You would have to do something like select sum(sales + refunds) to total_amount
But don't take my word for it. Run some test queies, play with the sql some so you can see the results.
.