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
Cannot load filter Error: ORA-00979: not a GROUP BY expression #28327
Comments
@mistercrunch Can you help me, I have not been able to solve it for several weeks |
I faced this problem with superset oracle connection. There is a connection with oracle and there is data, but there is this error in the filter, this process happened after connecting to oracle postres, this problem is not there, because it is the superset settings or the queries are wrong? |
Hi @mujohiddin. Oracle does not support |
@michael-s-molina |
@michael-s-molina GROUP BY 1 with GROUP BY "CODE". |
1 - Go to the filter configuration |
@michael-s-molina , Moreover, I cannot create Table, Pivot charts , they are failling with the same error : |
@rusackas @betodealmeida Does any of you have an Oracle instance to test this? Or do you know who's the Oracle dialect maintainer? |
@mujohiddin Can you also share what was the previous version where this was working? |
|
Sadly, I don't know of anyone with Oracle. It's still on the wish list in the rolodex, if anyone on this thread would be kind enough to sign up. |
@mistercrunch |
I have also faced this issue with Oracle, |
i have old version working with oracle but i have problems in new version, do i need to add some parts from old version or some scprits? exactly in which python file or class is this generation process taking place. If you tell me that, I will send it to you, and we will compare the status of the two versions @mistercrunch |
No, the solution has not been found yet. I am waiting for a response from contributions |
Let's see if our AI overlords can help at all... |
To address the "ORA-00979: not a GROUP BY expression" error in Superset when using Oracle, it seems the issue stems from Oracle's lack of support for the "GROUP BY 1" shorthand syntax, which is not an issue with databases like PostgreSQL that support this syntax. The error arises because Oracle requires explicit column names in the GROUP BY clause instead of positional references. A potential solution involves customizing the SQL compilation process in SQLAlchemy, which Superset uses to interact with databases. You can create a custom SQLAlchemy dialect for Oracle or modify the existing one to ensure that GROUP BY expressions are correctly handled. This involves overriding the Additionally, changes in newer versions of Superset, particularly in how SQL statements are generated for Oracle databases, could contribute to this issue. These changes might involve adjustments in time grain expressions, date-time conversion methods, and enforced column alias quoting, which could affect the generation of GROUP BY clauses. A specific commit addressing a similar issue by modifying the SQL generation logic in Superset to comply with Oracle's requirements might also offer a clue. This commit ensures that columns used in the ORDER BY clause are included in the SELECT clause, as required by Oracle. Implementing these solutions requires a good understanding of Python, SQLAlchemy, and Superset's architecture. If you're comfortable making these adjustments, you could potentially resolve the issue. Otherwise, it might be beneficial to reach out to the Superset community for further assistance or consider hiring a developer with the necessary expertise.
|
Debugging this actually only requires having access to the Oracle SQLA dialect. I assume @mujohiddin you are using the default dialect included in SQLA? If so, I think we may be doing something wrong, as I'd be extremely surprised if SQLA has bug of this magnitude.. |
I'm not clear on what may trigger And why would it do it for Oracle, one of the databases that seems to not support this (?) |
That's the question why superset is doing this? |
Bug description
I faced this problem with superset oracle connection. There is a connection with oracle and there is data, but there is this error in the filter, this process happened after connecting to oracle postres, this problem is not there, because it is the superset settings or the queries are wrong?
and where does such an error 1 appear in the console?
How to reproduce the bug
I don't know
Screenshots/recordings
Superset version
3.1.2
Python version
3.9
Node version
16
Browser
Chrome
Additional context
No response
Checklist
The text was updated successfully, but these errors were encountered: