kainchow commented on issue #29991:
URL: https://github.com/apache/superset/issues/29991#issuecomment-2306487107

   I made a temporary change to `superset/sql_parse.py` which avoids this 
issue, but it may cause other problems, so someone still needs to fix the bug!
   ```python
   def _extract_tables_from_sql(self) -> set[Table]:
       """
       Extract all table references in a query.
   
       Note: this uses sqlglot, since it's better at catching more edge cases.
       """
       try:
           statements = parse(self.stripped(), dialect=self._dialect)
       except ParseError as ex:
           statements = []
       except SqlglotError as ex:
           ...
   ```


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