SUM(expression)

Description: Returns the sum of expression. Generally used with GROUP BY clause, but otherwise operates on all rows returned.

If the set has no rows, it returns NULL.

Example:

SELECT city_name, SUM(temperature)
  FROM weather
  GROUP BY city_name

returns the minimum temperature recorded for each city in table weather.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.12.162.37