Skip to content
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

How to add greater than filter in apache superset? #9974

Closed
sedhha opened this issue Jun 3, 2020 · 14 comments
Closed

How to add greater than filter in apache superset? #9974

sedhha opened this issue Jun 3, 2020 · 14 comments
Labels
dashboard:native-filters Related to the native filters of the Dashboard enhancement:committed Enhancement planned / committed by a contributor explore:filter Related to filters in Explore

Comments

@sedhha
Copy link

sedhha commented Jun 3, 2020

Has superset changed its folder locations and interface? From a youtube tutorial, I found these options available in filter box:
image
But what my filter looks like is:
image

I want to apply a filter box which gives me flexibility to apply a filter over ranges. For example, this is my table:
image

I want to add a filter where it should display only those table results where videos>=100 and videos<=10000. Although filter allows me to select multiple value but what it doesn't allow me is to apply ranges, and as you know there are so many values between these two ranges, it gets very inefficient to apply these filters.

I tried to apply the filter as shown below:
image
image
image
But how it works is this way:
image
When we look at time filter:
image
It works well and offers tons of customization, I was just curious if we can dynamically filter time then why not other values. Please do let me know if you have something for this.

Additional context
Add any other context or screenshots about the feature request here.

@sedhha sedhha added the enhancement:request Enhancement request submitted by anyone from the community label Jun 3, 2020
@issue-label-bot
Copy link

Issue Label Bot is not confident enough to auto-label this issue. See dashboard for more details.

@aussat
Copy link

aussat commented Jul 6, 2020

@sedhha Agree, this would be great if dynamic filters added to Superset. I am not sure if it works for your problem, but you can try to apply CASE function to the range you need to filter. In order to do this, just add a new column in datasource editor with required SQL, then use this column in FIlter View.

CASE
    WHEN condition1 THEN result1
    WHEN condition2 THEN result2
    WHEN conditionN THEN resultN
    ELSE result
END;

@sedhha
Copy link
Author

sedhha commented Jul 6, 2020

Oh amaing @aussat Thanks a lot will try this out.

@stale
Copy link

stale bot commented Sep 5, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. For admin, please label this issue .pinned to prevent stale bot from closing the issue.

@stale stale bot added the inactive Inactive for >= 30 days label Sep 5, 2020
@stale stale bot removed the inactive Inactive for >= 30 days label Sep 5, 2020
@AsjadMahmood
Copy link

Any update how we can add less than greater than filter in Filter Box so we can apply it on the dashboard, we do get to add these filters in other charts, but not in Filter Box

@stale
Copy link

stale bot commented Nov 26, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. For admin, please label this issue .pinned to prevent stale bot from closing the issue.

@stale stale bot added the inactive Inactive for >= 30 days label Nov 26, 2020
@lozbrown
Copy link

@junlincc
Any chance this might be possible soon?

@stale stale bot removed the inactive Inactive for >= 30 days label Dec 21, 2020
@junlincc junlincc added explore:filter Related to filters in Explore and removed filter labels Jan 3, 2021
@aonurdemir
Copy link

Although we can filter columns by range in explore chart screen, it is weird that we cannot filter columns by range in dashboard filters. Any progress?

@vialcollet
Copy link

Hi all
I agree this is a missing functionality.
It can be requiered to offer the user the possiblity to zoom on specific ranges of some numerical fields.
For example I need it for some bubble charts.

@villebro
Copy link
Member

@aonurdemir @vialcollet the new native filters feature is currently under heavy development, and we've already implemented a range filter which adds this feature (greater than, less than and range). Expect the feature to be in testable state fairly soon, but general availability is probably still a few months away.

@junlincc junlincc added enhancement:committed Enhancement planned / committed by a contributor and removed enhancement:request Enhancement request submitted by anyone from the community labels Feb 15, 2021
@junlincc
Copy link
Member

while you are waiting for the new features, you could try using jinja template to create range filter as workaround.
we dont have an exact tutorial for it yet, but you can refer to ..
https://www.youtube.com/watch?v=AcnNlIkfCiI
https://www.youtube.com/watch?v=dE1QlhunWMs

@vialcollet

@junlincc junlincc added the dashboard:native-filters Related to the native filters of the Dashboard label Apr 21, 2021
@samah-m8
Copy link

Hello,
This feature is not in 1.3.2, any idea when will it be added?

@erfanu25
Copy link

erfanu25 commented Oct 4, 2022

Is there any update for this in superset 2.0 ?

@villebro
Copy link
Member

villebro commented Oct 4, 2022

@erfanu25 please take a look at the Numerical Range Filter in Dashboard Native Filters which has been available for quite some time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dashboard:native-filters Related to the native filters of the Dashboard enhancement:committed Enhancement planned / committed by a contributor explore:filter Related to filters in Explore
Projects
None yet
Development

No branches or pull requests