diff options
author | Joas Schilling <coding@schilljs.com> | 2018-10-19 16:44:28 +0200 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2018-11-08 15:44:45 +0100 |
commit | bb352fb667e87ea0829f1da5f9e85c34bdefe9fa (patch) | |
tree | cd243856dcfec5708528418b55269e3d7feed53a /tests/lib/DB | |
parent | 78fd8ab0fd362fd5d568dfc5b47a02158e62d51c (diff) | |
download | nextcloud-server-bb352fb667e87ea0829f1da5f9e85c34bdefe9fa.tar.gz nextcloud-server-bb352fb667e87ea0829f1da5f9e85c34bdefe9fa.zip |
Use the defined func()->count() instead of manual counting
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'tests/lib/DB')
-rw-r--r-- | tests/lib/DB/QueryBuilder/ExpressionBuilderTest.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/lib/DB/QueryBuilder/ExpressionBuilderTest.php b/tests/lib/DB/QueryBuilder/ExpressionBuilderTest.php index 1bf42d230fe..f5dc2a07246 100644 --- a/tests/lib/DB/QueryBuilder/ExpressionBuilderTest.php +++ b/tests/lib/DB/QueryBuilder/ExpressionBuilderTest.php @@ -400,7 +400,7 @@ class ExpressionBuilderTest extends TestCase { $this->createConfig($appId, 11, 'underscore'); $query = $this->connection->getQueryBuilder(); - $query->select($query->createFunction('COUNT(*) AS `count`')) + $query->select($query->func()->count('*', 'count')) ->from('appconfig') ->where($query->expr()->eq('appid', $query->createNamedParameter($appId))) ->andWhere(call_user_func([$query->expr(), $function], 'configvalue', $query->createNamedParameter($value, $type), IQueryBuilder::PARAM_STR)); |