The MySQL sum() function returns the total summed value of a numeric field. It is used when you need to addition the numeric fields value.
To count or calculate number of rows in a table, use the following syntax:
tablename: The table name from which you want to fetch records.
col1: The column or field name that will be summed. It will summed the numeric field values.
In the above example, we are adding "workingHours" numeric field value in tblCustomerLoan" table.
You can use MySQL Command Line Client to summed numeric field value in the specified table. It will look like this: