fardin-developer opened a new issue, #33552: URL: https://github.com/apache/superset/issues/33552
### Bug description ## Description When using **Mixed Time Series Charts** in Superset that involve **multiple queries**, each split by a dimension (e.g., `explore_name`, `module`, `category`), the **legend becomes ambiguous**. Currently, it aggregates all legend entries together without clearly indicating **which metric belongs to which query**. This creates confusion, especially when the dimension values overlap between queries. ## Problem In the current state, the tooltip and legend display series like this: ```yaml EXP UI: 25.66 EXP UI (1): 49 OKR: 15 ``` There is no visual separation or naming pattern to distinguish which entry comes from **Query A** vs **Query B**. This is especially problematic when both queries contain the same dimension values (like `EXP UI`, `OKR`, `SQL LAB`, etc.). ## Steps to Reproduce ### 1. Create Mixed Chart ### 2. Configure Query A - Set up your first query (e.g., `P75ResponseTime`) - Choose a dimension to split by (e.g., `explore_name`) ### 3. Configure Query B - Set up your second query (e.g., `QueryCount`) - Choose the same dimension to split by (e.g., `explore_name`) ### 4. Observe the Issue - Run the chart and hover over data points - In the tooltip, you'll see dimension values like `EXP UI` appearing multiple times - There is **no clear indication** of which `EXP UI` value belongs to **Query A** vs **Query B** ## Example In a scenario where: - **Query A** returns `P75ResponseTime` - **Query B** returns `QueryCount` The tooltip/legend currently shows: ```java EXP UI: 25.66 EXP UI (1): 49 ``` But users cannot tell which metric is from which query without cross-checking query logic or hovering one-by-one.   ## Proposed Solution Change the legend and tooltip formatting to: Option A ```graphql P75ResponseTime (Query A), EXP UI: 25.66 QueryCount (Query B), EXP UI: 49 ``` Or Option B ```graphql EXP UI (Query A): 25.66 EXP UI (Query B): 49 ``` This clearly associates each metric with its originating query and improves the overall **readability and usability** of mixed time series charts with multiple queries. ## Benefits - **Enhanced UX**: Users can immediately identify which data belongs to which query - **Reduced Confusion**: Eliminates ambiguity when dimension values overlap between queries - **Improved Dashboard Readability**: Makes complex multi-query charts more accessible - **Better Data Analysis**: Facilitates faster decision-making by providing clear context ## Technical Considerations - Modify legend rendering logic to include query identifiers - Update tooltip formatting to display query source information - Ensure backward compatibility with existing charts - Consider user preferences for enabling/disabling this feature ## References - [[Superset Discussion #29773](https://github.com/apache/superset/discussions/29773)] ## Additional Notes This enhancement would particularly benefit: - Operations teams monitoring multiple metrics simultaneously - Business analysts creating complex dashboards with overlapping dimensions - Data engineers working with multi-source visualizations ### Screenshots/recordings _No response_ ### Superset version master / latest-dev ### Python version 3.9 ### Node version 16 ### 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
