Max方法:Max API-Medoo使用指南
2014-06-04 22:53
267 查看
上一篇《统计方法:Count API-Medoo使用指南》中介绍了如何使用Medoo的Count方法来统计记录的行数。本篇将要介绍使用Max方法来获取列的最大值。
Max方法:Max API
使用Max方法获取列的最大值。
返回值: [number]:列的最大值。
提示:返回值的数据类型是数字。
Medoo版本: 0.9.1.1
原文标题: Max方法:Max API-Medoo使用指南
原文链接: http://loiy.net/post/610.html
Max方法:Max API
使用Max方法获取列的最大值。
max($table, $column, $where) //table [string]: 表名 //column [string]: 将要被计算的目标列 //where (可选)[array]:WHERE子句筛选记录
返回值: [number]:列的最大值。
提示:返回值的数据类型是数字。
$database = new medoo("my_database"); $max = $database->max("account", "age", [ "gender" => "female" ]); echo "The age of oldest female user is " . $max;
Medoo版本: 0.9.1.1
原文标题: Max方法:Max API-Medoo使用指南
原文链接: http://loiy.net/post/610.html
相关文章推荐
- 取得方法:Get API-Medoo使用指南
- 求和方法:Sum API-Medoo使用指南
- Has方法:Has API-Medoo使用指南
- Min方法:Min API-Medoo使用指南
- 引用方法:Quote API-Medoo使用指南
- 删除方法:Delete API-Medoo使用指南
- 平均值方法:Avg API-Medoo使用指南
- 最后查询方法:Last Query API-Medoo使用指南
- 数据库信息方法:Info API-Medoo使用指南
- 错误方法:Error API-Medoo使用指南
- 查询方法:Query API-Medoo使用指南
- 统计方法:Count API-Medoo使用指南
- 替换方法:Replace API-Medoo使用指南
- 更新方法:Update API-Medoo使用指南
- 使用Hibernate获取最大值(max)的三种方法
- ini_set()函数的使用 以及 post_max_size,upload_max_filesize的修改方法
- oracle 10g中的SGA_MAX_SIZE与SGA_TARGET的使用方法
- DB2 9 使用开辟(733 测验)认证指南,第 1 部分: 数据库对象与编程方法(4)
- Hibernate -- 使用Hibernate获取最大值(max)的三种方法(转)
- 使用Hibernate获取最大值(max)的三种方法(转载)