Archive:PHP and MySQL Programming/Common Functions and Operators: Difference between revisions
Appearance
wikademia>Darklama m Programming:PHP and MySQL:Common Functions and Operators moved to Programming:PHP and MySQL/Common Functions and Operators: fixing copy+paste move |
wikademia>Wikademia m moved PHP and MySQL Programming/Common Functions and Operators to Archive:PHP and MySQL Programming/Common Functions and Operators over redirect |
||
| (6 intermediate revisions by 2 users not shown) | |||
| Line 1: | Line 1: | ||
== COUNT == | == COUNT == | ||
| Line 11: | Line 7: | ||
mysql> SELECT SUM(`field_name`) FROM `table_name`; | mysql> SELECT SUM(`field_name`) FROM `table_name`; | ||
[[ | [[../Basic Queries/|Previous: Basic Queries]] | [[../|TOC]] | [[../XML and PHP/|Next: XML and PHP]] | ||
[[Category:MySQL]] | |||
[[Category:PHP and MySQL Programming|{{SUBPAGENAME}}]] | |||
Latest revision as of 07:37, 12 June 2009
COUNT
mysql> SELECT COUNT(*|`field_name`) FROM `table_name`;
SUM
mysql> SELECT SUM(`field_name`) FROM `table_name`;
[[../Basic Queries/|Previous: Basic Queries]] | [[../|TOC]] | [[../XML and PHP/|Next: XML and PHP]]