ITADN

Фасетный поиск. Отображение всех вариантов

#4531Openden1a 创建于 2026-04-28
D
den1acommented
### Proposal: At the moment, faceted search returns only the available options, which greatly limits the possible use cases for e-commerce filters. The example is taken from the official course [https://play.manticoresearch.com/faceting/](https://play.manticoresearch.com/faceting/) **Problem:** when clicking any value in the rating filters, all other rating options, years, etc. disappear. <img width="907" height="798" alt="Image" src="https://github.com/user-attachments/assets/f9f4e4ce-424d-4e95-a340-81a2b9d2015b" /> > <img width="894" height="707" alt="Image" src="https://github.com/user-attachments/assets/b560c397-f993-480e-9c95-68fe07ea274d" /> **Solution:** it would be great to have the ability to retrieve all available options by using an additional flag in the query. In the screenshot, a record with a zero `count(*)` value was added. <img width="1576" height="996" alt="Image" src="https://github.com/user-attachments/assets/58c281ef-3b59-4393-a730-86d8be9c2b13" /> **Benefit:** thanks to this functionality enhancement, it would become possible to build very concise SQL queries for displaying filters in an e-commerce store. Currently, it requires multiple multi-queries [https://manual.manticoresearch.com/Searching/Multi-queries](https://manual.manticoresearch.com/Searching/Multi-queries) The screenshots below demonstrate a typical implementation of filters in an online store. <img width="310" height="484" alt="Image" src="https://github.com/user-attachments/assets/5ec172d1-0afb-4523-86ff-3a2f6e51c498" /> > <img width="273" height="510" alt="Image" src="https://github.com/user-attachments/assets/69a01874-f7aa-4f01-a765-523d5c1654d3" /> ### Checklist: <sup>To be completed by the assignee. Check off tasks that have been completed or are not applicable.</sup> <details> - [ ] Implementation completed - [ ] Tests developed - [ ] Documentation updated - [ ] Documentation reviewed - [ ] OpenAPI YAML updated and issue created to rebuild clients </details>
1 条评论