~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to docs/functions/aggregatefunctions.rst

  • Committer: Andrew Hutchings
  • Date: 2011-02-15 22:03:42 UTC
  • mto: (2172.1.2 build)
  • mto: This revision was merged to the branch mainline in revision 2173.
  • Revision ID: andrew@linuxjedi.co.uk-20110215220342-k4tveraug3bpy2v5
Make fixes to temporal docs
Make a few minor docs cleanups/fixes
Start using syntax-highlighting code blocks

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
 
4
4
SQL group (aggregate) functions operate on sets of values. If you use an aggregate function in a statement containing no GROUP BY clause, it is equivalent to grouping on all rows.
5
5
 
6
 
General syntax for aggregate functions is: ::
 
6
General syntax for aggregate functions is:
 
7
 
 
8
.. code-block:: mysql
7
9
 
8
10
        SELECT "function type" ("column_name")
9
11
        FROM "table_name";
10
 
 
11
 
The following are examples of aggregate functions:
 
12
 
 
13
The following are examples of aggregate functions:
12
14
 
13
15
**AVG**:  Return the average value of the argument. (Does not work with temporal values unless first converted to numeric values.)
14
16