diff --git a/typo3/sysext/install/Classes/Updates/ExtensionManagerTables.php b/typo3/sysext/install/Classes/Updates/ExtensionManagerTables.php
index db27c56e9c028b7e66042c8c20e5a4a87dae7b7b..082efd3a0879a6e01fbb01fdc1d5f310cf60498b 100644
--- a/typo3/sysext/install/Classes/Updates/ExtensionManagerTables.php
+++ b/typo3/sysext/install/Classes/Updates/ExtensionManagerTables.php
@@ -14,6 +14,7 @@ namespace TYPO3\CMS\Install\Updates;
  * The TYPO3 project - inspiring people to share!
  */
 
+use TYPO3\CMS\Core\Database\ConnectionPool;
 use TYPO3\CMS\Core\Utility\ExtensionManagementUtility;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 
@@ -80,7 +81,9 @@ class ExtensionManagerTables extends AbstractUpdate
         $updateStatements = $this->getUpdateStatements();
         if (empty($updateStatements)) {
             // Get count of rows in repository database table
-            $count = $this->getDatabaseConnection()->exec_SELECTcountRows('*', 'tx_extensionmanager_domain_model_repository');
+            $count = GeneralUtility::makeInstance(ConnectionPool::class)
+                ->getConnectionForTable('tx_extensionmanager_domain_model_repository')
+                ->count('*', 'tx_extensionmanager_domain_model_repository', []);
             if ($count === 0) {
                 $result = true;
             }