-
Notifications
You must be signed in to change notification settings - Fork 14.4k
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
SQL parser sqlglot does not support impala dialect, so datasets in IMPALA stopped working. #32143
Comments
The issue you're experiencing is related to the use of sqlglot for SQL parsing in Apache Superset version 4.1.1, which does not support the Impala SQL dialect. This is causing errors when creating datasets from SQL Lab queries, even though the queries themselves execute correctly. Currently, Superset handles unsupported SQL dialects by using custom implementations. However, for Impala, there doesn't seem to be a built-in workaround or custom implementation in the codebase specifically for this dialect. You might need to consider implementing a custom parser or handling logic for Impala SQL within your Superset setup to address this issue. For now, you could explore the possibility of extending or customizing sqlglot to support Impala, although this would require significant development effort. Alternatively, you might need to wait for an update from the Superset maintainers that addresses this limitation or consider contributing a solution if you're able to develop one. To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other |
In the logs: |
@betodealmeida might have an idea what's happening here. |
Bug description
Hi!
![Image](https://private-user-images.githubusercontent.com/132096459/409984569-8bd04f3e-bd8f-4364-8516-c57cdb746847.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyNjE1OTcsIm5iZiI6MTczOTI2MTI5NywicGF0aCI6Ii8xMzIwOTY0NTkvNDA5OTg0NTY5LThiZDA0ZjNlLWJkOGYtNDM2NC04NTE2LWM1N2NkYjc0Njg0Ny5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwMjExJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDIxMVQwODA4MTdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1hMWE1Nzg2MDBmNjM4NDkwZmI3MDVkMjg5NTQ1Y2VlYjJjMzRmMjRlNzI1YWE3MjYwYmNmMGUzNjE2Yzc1ZTE4JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.NcSMznfO0XX4-NJ2g5udZue2c22fwHmx6rqf6glG0SE)
I am using IMPALA DB and after upgrading to version 4.1.1 the most of the datasets not working.
When executing queries in SQL LAB - queries work correctly, but it is impossible to create a dataset from queries. The error: “Fatal error”
appears.
But the dataset is still created - but when we open dataset it I get an error -
and
“Failed to load chart data:
![Image](https://private-user-images.githubusercontent.com/132096459/409984393-2b0cca2d-cdf1-4c46-928a-7dad7d38a3e8.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyNjE1OTcsIm5iZiI6MTczOTI2MTI5NywicGF0aCI6Ii8xMzIwOTY0NTkvNDA5OTg0MzkzLTJiMGNjYTJkLWNkZjEtNGM0Ni05MjhhLTdkYWQ3ZDM4YTNlOC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwMjExJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDIxMVQwODA4MTdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1kYjVmZDI1YzI3OWZlOWEzZjFmMjRlNDhiYzljYzk2Y2ZmMzg1MDJlMWMzMjU5ZmY3MTYwOTY3NzBkZDBlYjZjJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.PKWNsTW4k9j-eL3xEhjKHqZXFSzah-ErHlQSazCxam0)
Error parsing near 'Query' at line 2:35”.
In the developer console you can see the following error:
![Image](https://private-user-images.githubusercontent.com/132096459/409985611-7b7cb4e4-c2b1-4939-b3de-02ef1969e2ca.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyNjE1OTcsIm5iZiI6MTczOTI2MTI5NywicGF0aCI6Ii8xMzIwOTY0NTkvNDA5OTg1NjExLTdiN2NiNGU0LWMyYjEtNDkzOS1iM2RlLTAyZWYxOTY5ZTJjYS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwMjExJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDIxMVQwODA4MTdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1hYzc5MGE2MWIzZTI3ZTkwNTRjOTYwMjI3Mjk5Mzg0YmE0YmFkOWMyOThhZDM2ZWYxZWU3NzMxMzZmMDJmZjA3JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.bH06-aI3_s2KKByy1pLcd6QxQmFqrIUqg85-OZksed0)
When opening a dataset for editing, you can see next error:
A little researching the problem - found that the SQL analysis was improved (#26786).
In favor of SQL parser sqlglot. Which does not support Impala dialect.
I also encounter a similar error in SQL LAB.
(#30551)
Screenshots/recordings
No response
Superset version
4.1.1
Python version
3.9
Node version
16
Browser
Chrome
Additional context
No response
Checklist
The text was updated successfully, but these errors were encountered: