You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2018/05/17 17:42:35 UTC

[GitHub] timifasubaa commented on a change in pull request #5023: [sqllab] force limit queries only when there is no existing limit

timifasubaa commented on a change in pull request #5023: [sqllab] force limit queries only when there is no existing limit
URL: https://github.com/apache/incubator-superset/pull/5023#discussion_r189043307
 
 

 ##########
 File path: superset/sql_lab.py
 ##########
 @@ -185,7 +186,8 @@ def handle_error(msg):
                 query.user_id, start_dttm.strftime('%Y_%m_%d_%H_%M_%S'))
         executed_sql = superset_query.as_create_table(query.tmp_table_name)
         query.select_as_cta_used = True
-    elif (query.limit and superset_query.is_select()):
+    elif (not query.limit and superset_query.is_select() and SQL_MAX_ROWS):
 
 Review comment:
   @mistercrunch  I tested it and it works correctly.
   
   I changed the place where query.limit is defined upstream and it is None only when it is not specified. It is only in those cases that we append the default limit to the end. 

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org