superset icon indicating copy to clipboard operation
superset copied to clipboard

How to add greater than filter in apache superset?

Open sedhha opened this issue 6 years ago • 14 comments

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 avatar Jun 03 '20 06:06 sedhha

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

issue-label-bot[bot] avatar Jun 03 '20 06:06 issue-label-bot[bot]

@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;

aussat avatar Jul 06 '20 13:07 aussat

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

sedhha avatar Jul 06 '20 14:07 sedhha

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[bot] avatar Sep 05 '20 20:09 stale[bot]

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

AsjadMahmood avatar Sep 16 '20 07:09 AsjadMahmood

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[bot] avatar Nov 26 '20 22:11 stale[bot]

@junlincc Any chance this might be possible soon?

lozbrown avatar Dec 21 '20 13:12 lozbrown

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?

aonurdemir avatar Jan 18 '21 13:01 aonurdemir

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.

vialcollet avatar Feb 14 '21 13:02 vialcollet

@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.

villebro avatar Feb 14 '21 15:02 villebro

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 avatar Feb 15 '21 06:02 junlincc

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

samah-m8 avatar Nov 11 '21 17:11 samah-m8

Is there any update for this in superset 2.0 ?

erfanu25 avatar Oct 04 '22 05:10 erfanu25

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

villebro avatar Oct 04 '22 07:10 villebro