diff --git a/core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorage.php b/core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorage.php
index 1942f6d..3ea9b35 100644
--- a/core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorage.php
+++ b/core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorage.php
@@ -1632,17 +1632,10 @@ public function countFieldData($storage_definition, $as_bool = FALSE) {
     //   storage. See https://www.drupal.org/node/2337753.
     $count = 0;
     if (isset($query)) {
-      // If we are performing the query just to check if the field has data
-      // limit the number of rows.
-      if ($as_bool) {
-        $query->range(0, 1);
-      }
-      else {
-        // Otherwise count the number of rows.
-        $query = $query->countQuery();
-      }
+      $query = $query->countQuery();
       $count = $query->execute()->fetchField();
     }
+
     return $as_bool ? (bool) $count : (int) $count;
   }
 
