diff --git a/app/code/Magento/CatalogSearch/Model/Resource/Search/Collection.php b/app/code/Magento/CatalogSearch/Model/Resource/Search/Collection.php index 1ad747c1f4d88..728eca057ae94 100644 --- a/app/code/Magento/CatalogSearch/Model/Resource/Search/Collection.php +++ b/app/code/Magento/CatalogSearch/Model/Resource/Search/Collection.php @@ -230,7 +230,7 @@ protected function _getSearchEntityIdsSql($query) } } - $ifValueId = $this->getConnection()->getCheckSql('t2.value_id > 0', 't2.value', 't1.value'); + $ifValueId = $this->getConnection()->getIfNullSql('t2.value', 't1.value'); foreach ($tables as $table => $attributeIds) { $selects[] = $this->getConnection()->select()->from( array('t1' => $table),