-
Notifications
You must be signed in to change notification settings - Fork 14.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Modify Automatic “IN” Filter to Support “LIKE” Search for Categorical Filters #32276
Comments
Hey @chrisdukeLlama! I'm here to help you with any bugs, questions, or contributions you have for Apache Superset. Let me know how I can assist you! The logic for automatically applying filters to categorical searches in Superset is located in the Additionally, the backend logic in To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other |
Excuse me imprecise previous question
|
The logic that defaults to using "IN" for categorical filters in Superset is implemented in the To modify the filtering logic to allow text-based "LIKE" searches instead of "IN", you would need to adjust this logic to set the operator to "LIKE" or "ILIKE" based on your requirements. This would involve changing the default operator in the relevant part of the code where the filter is applied. As for planned features or workarounds for full-text search in dashboards, I wasn't able to find specific information in the repository. You might need to implement custom logic or modifications to achieve full-text search capabilities. To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other |
@dosu Thanks for confirming where "IN" is set!
|
To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other |
@dosu thanks, I decided that it might be the easiest way to solve my problem by downgrading to an older version of superset that still includes the filter box, which version would that be? That would work with like search on text columns right? |
The Filter Box component was removed in Apache Superset version 4.0.0. Therefore, you would need to downgrade to a version prior to 4.0.0 to use the Filter Box [1][2]. The Filter Box supported both 'LIKE' and 'ILIKE' searches on text columns, allowing for partial and case-insensitive matching [3][4][5]. To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other |
@dosu so the elderly are right when they say that everything was better back in the days |
It's often the case that older versions have features that some users find indispensable. If the Filter Box meets your needs, reverting to a version before 4.0.0 could be a practical solution for now. Just keep in mind that older versions might lack newer features or security updates. If you decide to go this route, ensure your environment is secure and consider contributing to the project if you have ideas for improvements. If you need further assistance with the downgrade or any other questions, feel free to ask! To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other |
@dosu the data world would be much easier if there was only categorical data for me as well, but there isn't |
Indeed, working with diverse data types can present challenges, especially when it comes to filtering and searching. If you have any more questions or need further assistance with Superset or data handling, feel free to reach out. I'm here to help! To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other |
@dosu you said: The Filter Box component was removed in Apache Superset version 4.0.0. Therefore, you would need to downgrade to a version prior to 4.0.0 to use the Filter Box [1][2]. The Filter Box supported both 'LIKE' and 'ILIKE' searches on text columns, allowing for partial and case-insensitive matching [3][4][5]. but in 3.0.2 I get only: so how do I get a free text filter? |
The Filter Box component was last available in Apache Superset version 3.x before its removal in version 4.0.0 [1]. If you're using version 3.0.2 and not seeing the expected Filter Box options, it might be due to configuration settings or specific dashboard setups. To enable free text filtering, you might need to ensure that the Filter Box is properly configured in your dashboard. If the Filter Box is not appearing as expected, consider checking the dashboard's configuration or exploring other available filter components that might offer similar functionality. If the Filter Box is not meeting your needs, you may need to explore custom solutions or modifications to achieve the desired filtering capabilities. To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other |
In previous discussions about this, the various implementations of like/ilike were shot down because on large datasets they can cause a huge performance regression. I can't recall how hard it would be, but it may be possible to add a checkbox when configuring a filter to enable/disable the fuzzier search options, including the options like |
@rusackas |
Description:
Currently, Superset automatically applies an “IN” filter when filtering categorical values in dashboards. I want to modify this behavior to use a “LIKE” search instead, but I can’t find where this logic is implemented in the codebase.
Question:
• Where in the Superset code is the logic for automatically applying “IN” filters to categorical searches?
• Is there an existing way to override this behavior, or would this require a code modification?
Why This Matters:
• The current implementation forces exact matches, which is not suitable for my use case.
• A “LIKE” search would allow for partial matching, making filters more flexible, especially for datasets with non-standardized values.
• I understand the performance concerns with LIKE searches on large datasets, but for smaller datasets, this is a much-needed feature.
Additional Context:
• I read that the Filter Box would have allowed this, but it has been removed.
• I followed previous discussions about keeping it and understand the arguments, but right now, there is no alternative that works for my case.
• I appreciate Apache Superset because it displays text much better than Grafana or Metabase, but for text data, the lack of flexible filtering is a big limitation.
Would appreciate any pointers on which file or function controls this behavior.
The text was updated successfully, but these errors were encountered: