Closed
Description
Preconditions (*)
- Magento 2 version 2.2.6
Steps to reproduce (*)
- In "vendor/magento/module-catalog-search/etc/search_request.xml" change
<query xsi:type="boolQuery" name="quick_search_container" boost="1">
<queryReference clause="should" ref="search" />
<queryReference clause="must" ref="category"/>
<queryReference clause="must" ref="price"/>
<queryReference clause="must" ref="visibility"/>
</query>
to
<query xsi:type="boolQuery" name="quick_search_container" boost="1">
<queryReference clause="must" ref="search" />
<queryReference clause="must" ref="category"/>
<queryReference clause="must" ref="price"/>
<queryReference clause="must" ref="visibility"/>
</query>
So that the search query "blue boot" only shows products with both the words.
2. Add a product in the back-end with a name with a dash (-) in the name.
For instance "Lakboot Black Mat New A-327 N118" in my case
3. On the frontend search for that product.
So with my example you would search for "A-327".
4. Now when you have the search clause for must nothing is going to show up.
Expected result (*)
- You would expect the product to show up
Actual result (*)
- There are no results found