villebro commented on issue #4412: Comment row at end of query in SQL Lab fails 
to render in Explore window
   Thanks, that looks much better:
   diff --git a/superset/connectors/sqla/ 
   index b2e21c7d..5792498a 100644
   --- a/superset/connectors/sqla/
   +++ b/superset/connectors/sqla/
   @@ -423,7 +423,7 @@ class SqlaTable(Model, BaseDatasource):
        def get_from_clause(self, template_processor=None, db_engine_spec=None):
            # Supporting arbitrary SQL statements in place of tables
            if self.sql:
   -            from_sql = self.sql
   +            from_sql = sqlparse.format(self.sql, strip_comments=True)
                if template_processor:
                    from_sql = template_processor.process_template(from_sql)
                if db_engine_spec:
   <img width="1076" alt="screen shot 2018-02-13 at 11 27 39" 
   Ok for PR?

This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:

With regards,
Apache Git Services

Reply via email to