diff options
Diffstat (limited to 'apps')
-rw-r--r-- | apps/dav/lib/CalDAV/CalDavBackend.php | 4 | ||||
-rw-r--r-- | apps/dav/lib/CardDAV/CardDavBackend.php | 2 | ||||
-rw-r--r-- | apps/files_sharing/lib/Command/CleanupRemoteStorages.php | 2 | ||||
-rw-r--r-- | apps/user_ldap/lib/Mapping/AbstractMapping.php | 2 |
4 files changed, 5 insertions, 5 deletions
diff --git a/apps/dav/lib/CalDAV/CalDavBackend.php b/apps/dav/lib/CalDAV/CalDavBackend.php index 60f163abcbf..187ba4ecdcf 100644 --- a/apps/dav/lib/CalDAV/CalDavBackend.php +++ b/apps/dav/lib/CalDAV/CalDavBackend.php @@ -213,7 +213,7 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription public function getCalendarsForUserCount($principalUri, $excludeBirthday = true) { $principalUri = $this->convertPrincipal($principalUri, true); $query = $this->db->getQueryBuilder(); - $query->select($query->createFunction('COUNT(*)')) + $query->select($query->func()->count('*')) ->from('calendars') ->where($query->expr()->eq('principaluri', $query->createNamedParameter($principalUri))); @@ -1045,7 +1045,7 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription $extraData = $this->getDenormalizedData($calendarData); $q = $this->db->getQueryBuilder(); - $q->select($q->createFunction('COUNT(*)')) + $q->select($q->func()->count('*')) ->from('calendarobjects') ->where($q->expr()->eq('calendarid', $q->createNamedParameter($calendarId))) ->andWhere($q->expr()->eq('uid', $q->createNamedParameter($extraData['uid']))) diff --git a/apps/dav/lib/CardDAV/CardDavBackend.php b/apps/dav/lib/CardDAV/CardDavBackend.php index eb94885d177..699248f7b17 100644 --- a/apps/dav/lib/CardDAV/CardDavBackend.php +++ b/apps/dav/lib/CardDAV/CardDavBackend.php @@ -117,7 +117,7 @@ class CardDavBackend implements BackendInterface, SyncSupport { public function getAddressBooksForUserCount($principalUri) { $principalUri = $this->convertPrincipal($principalUri, true); $query = $this->db->getQueryBuilder(); - $query->select($query->createFunction('COUNT(*)')) + $query->select($query->func()->count('*')) ->from('addressbooks') ->where($query->expr()->eq('principaluri', $query->createNamedParameter($principalUri))); diff --git a/apps/files_sharing/lib/Command/CleanupRemoteStorages.php b/apps/files_sharing/lib/Command/CleanupRemoteStorages.php index 2175982dfc1..a4e5f50b9b2 100644 --- a/apps/files_sharing/lib/Command/CleanupRemoteStorages.php +++ b/apps/files_sharing/lib/Command/CleanupRemoteStorages.php @@ -98,7 +98,7 @@ class CleanupRemoteStorages extends Command { public function countFiles($numericId, OutputInterface $output) { $queryBuilder = $this->connection->getQueryBuilder(); - $queryBuilder->select($queryBuilder->createFunction('COUNT(' . $queryBuilder->getColumnName('fileid') . ')')) + $queryBuilder->select($queryBuilder->func()->count('fileid')) ->from('filecache') ->where($queryBuilder->expr()->eq( 'storage', diff --git a/apps/user_ldap/lib/Mapping/AbstractMapping.php b/apps/user_ldap/lib/Mapping/AbstractMapping.php index c3f09fd6caa..7ec22b6b79c 100644 --- a/apps/user_ldap/lib/Mapping/AbstractMapping.php +++ b/apps/user_ldap/lib/Mapping/AbstractMapping.php @@ -311,7 +311,7 @@ abstract class AbstractMapping { */ public function count() { $qb = $this->dbc->getQueryBuilder(); - $query = $qb->select($qb->createFunction('COUNT(' . $qb->getColumnName('ldap_dn') . ')')) + $query = $qb->select($qb->func()->count('ldap_dn')) ->from($this->getTableName()); $res = $query->execute(); $count = $res->fetchColumn(); |