codeant-ai-for-open-source[bot] commented on PR #38369:
URL: https://github.com/apache/superset/pull/38369#issuecomment-4030506775

   ## **Sequence Diagram**
   
   This PR ensures saved AG Grid filters are applied only once per chart render 
cycle and adds a mapping that resolves metric and calculated column labels to 
valid SQL before executing filtered queries.
   
   ```mermaid
   sequenceDiagram
       participant User
       participant TableFrontend
       participant Backend
       participant Database
   
       User->>TableFrontend: Load table chart with saved filters
       TableFrontend->>TableFrontend: Apply saved filter model once and then 
strip it on re-render
       User->>TableFrontend: Add or modify AG Grid filters (including AND 
conditions)
       TableFrontend->>Backend: Send query with AG Grid filter clauses and 
metric SQL expressions
       Backend->>Backend: Build label to SQL map and resolve labels in WHERE 
and HAVING
       Backend->>Database: Execute query with resolved filter clauses
       Database-->>Backend: Return filtered rows
       Backend-->>TableFrontend: Return updated result set for grid display
   ```
   
   ---
   *Generated by [CodeAnt AI](https://codeant.ai)*
   


-- 
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]

Reply via email to