mistercrunch opened a new pull request, #34390: URL: https://github.com/apache/superset/pull/34390
When using the "Group remaining as Others" feature with series limits, the generated SQL contained an unquoted literal in the GROUP BY clause, causing queries to fail. Problem: - SQL was generated with: ELSE Others END (unquoted) - Should be: ELSE 'Others' END (quoted string literal) Root cause: 1. Used sa.literal_column("Others") which treats "Others" as a column name 2. make_sqla_column_compatible interfered with proper literal quoting in GROUP BY Solution: 1. Changed to sa.literal("Others") for proper string literal handling 2. Removed make_sqla_column_compatible from GROUP BY expressions since: - GROUP BY doesn't need aliases/labels - The labeling was interfering with SQLAlchemy's literal compilation Related to #34308 which introduced the "Group remaining as Others" feature. -- 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-unsubscr...@superset.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscr...@superset.apache.org For additional commands, e-mail: notifications-h...@superset.apache.org