You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "volume8208 (via GitHub)" <gi...@apache.org> on 2024/09/27 07:03:35 UTC
[I] Cannot Apply Filter in Dashboard to Google Sheet Data Source [superset]
volume8208 opened a new issue, #30413:
URL: https://github.com/apache/superset/issues/30413
### Bug description
When using a Google Sheets data source in Superset, filters applied through the Dashboard's Filter UI are not working. System throw error "Error: Invalid query: NO_COLUMN: null". However, manually applying SQL WHERE filters in SQL Lab works as expected. This issue prevents the use of filters through the Dashboard's UI, significantly limiting the functionality for non-technical users who rely on the Filter UI.
### How to reproduce the bug
- Connect a Google Sheets data source to Superset.
- Create a dashboard using this data source.
- Add a filter to the dashboard through the Filter UI.
- Observe that the filter does not apply correctly to the Google Sheets data.
- Go to SQL Lab and manually apply a SQL WHERE clause to the same data source.
- Observe that the filter works when applied through SQL Lab.
### Screenshots/recordings
<img width="1075" alt="Screenshot 2567-09-27 at 13 58 17" src="https://github.com/user-attachments/assets/bbd83793-054b-475b-8623-2b2fec94e327">
### Superset version
4.0.2
### Python version
3.10
### Node version
18 or greater
### Browser
Chrome
### Additional context
_No response_
### Checklist
- [X] I have searched Superset docs and Slack and didn't find a solution to my problem.
- [X] I have searched the GitHub issue tracker and didn't find a similar bug report.
- [X] I have checked Superset's logs for errors and if I found a relevant Python stacktrace, I included it here as text in the "additional context" section.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] Cannot Apply Filter in Dashboard to Google Sheet Data Source [superset]
Posted by "dosubot[bot] (via GitHub)" <gi...@apache.org>.
dosubot[bot] commented on issue #30413:
URL: https://github.com/apache/superset/issues/30413#issuecomment-2378549841
<!-- Greeting -->
Hey @volume8208! I'm here to help you with the issue you're facing in Superset. I'm a bot designed to assist with bug resolutions, answer questions, and guide you on becoming a contributor. Let's dive into resolving the problem together!
<!-- Answer -->
The issue with filters applied through the Dashboard's Filter UI not working for a Google Sheets data source, while manually applying SQL WHERE filters in SQL Lab works as expected, is likely due to compatibility checks and scope management in the Dashboard's Filter UI.
1. **Compatibility Checks**: The filters are checked for compatibility with the datasource. If the filters are incompatible, they are marked as `IndicatorStatus.Incompatible` and are not applied. This could be why the filters are not working when applied through the Dashboard's Filter UI <sup>[[1]](https://github.com/apache/superset/blob/master/superset-frontend/src/dashboard/components/nativeFilters/selectors.ts)</sup>.
2. **Scope Management**: The function `useSelectFiltersInScope` ensures that only filters within the active scope of the dashboard are applied. If the filters are out of scope, they will not be applied <sup>[[2]](https://github.com/apache/superset/blob/master/superset-frontend/src/dashboard/components/nativeFilters/state.ts)</sup>.
3. **Error Handling**: The error "NO_COLUMN: null" is generated when a column does not exist in the datasource. This is handled using the `SupersetError` class with the `COLUMN_DOES_NOT_EXIST_ERROR` type <sup>[[3]](https://github.com/apache/superset/blob/master/superset/errors.py)</sup><sup>[[4]](https://github.com/apache/superset/blob/master/superset/connectors/sqla/models.py)</sup>.
To address this issue, ensure that the filters are compatible with the Google Sheets data source and within the active scope of the dashboard. Additionally, verify that the columns referenced in the filters exist in the Google Sheets data source.
<!-- Dosu Comment Footer -->
*To continue talking to [Dosu](https://dosu.dev), mention @dosu.*
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] Cannot Apply Filter in Dashboard to Google Sheet Data Source [superset]
Posted by "3rg0t (via GitHub)" <gi...@apache.org>.
3rg0t commented on issue #30413:
URL: https://github.com/apache/superset/issues/30413#issuecomment-2893378343
I'd say @etiennemallo 's suggestion is a good workaround, but one shouldn't have to go thtrough the extra work to get filters to work.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] Cannot Apply Filter in Dashboard to Google Sheet Data Source [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on issue #30413:
URL: https://github.com/apache/superset/issues/30413#issuecomment-5039440615
Still no PR here after over a year of reports. The `DATETIME(<col>)` computed-column workaround a few of you landed on is the real fix until someone traces why Google Sheets columns aren't typed as temporal in the first place. Assuming this is still the case in 6.x? Looking into it...
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] Cannot Apply Filter in Dashboard to Google Sheet Data Source [superset]
Posted by "etiennemallo (via GitHub)" <gi...@apache.org>.
etiennemallo commented on issue #30413:
URL: https://github.com/apache/superset/issues/30413#issuecomment-2466210568
Hey @sundar68
From what I see the filter in question is a date filter
I faced the same issue for date-like filters, and I just ended up creating a computed property like so :
<computed date column> = DATETIME(<original date column>)
Don't forget to modify the charts with your computed property
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] Cannot Apply Filter in Dashboard to Google Sheet Data Source [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas closed issue #30413: Cannot Apply Filter in Dashboard to Google Sheet Data Source
URL: https://github.com/apache/superset/issues/30413
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] Cannot Apply Filter in Dashboard to Google Sheet Data Source [superset]
Posted by "ddobrinskiy (via GitHub)" <gi...@apache.org>.
ddobrinskiy commented on issue #30413:
URL: https://github.com/apache/superset/issues/30413#issuecomment-2536647174
facing the same issue
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] Cannot Apply Filter in Dashboard to Google Sheet Data Source [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on issue #30413:
URL: https://github.com/apache/superset/issues/30413#issuecomment-2839285863
Does @etiennemallo's suggestion effectively close this issue? I haven't had a chance to try to reproduce this issue, but it's been silent for a long time. Seems like you could add a calculated column in Superset's dataset editor, too.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] Cannot Apply Filter in Dashboard to Google Sheet Data Source [superset]
Posted by "lightseb (via GitHub)" <gi...@apache.org>.
lightseb commented on issue #30413:
URL: https://github.com/apache/superset/issues/30413#issuecomment-3886194492
up up up, same issue here with no solution :/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
Re: [I] Cannot Apply Filter in Dashboard to Google Sheet Data Source [superset]
Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on issue #30413:
URL: https://github.com/apache/superset/issues/30413#issuecomment-5434188909
#43355 fixed this - `GSheetsEngineSpec` was formatting Date-column filter bounds wrong, which is exactly the `NO_COLUMN: null` error here. Closing, but reopen if filtering still breaks on your sheet.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org