kkhatua commented on a change in pull request #1608: DRILL-6960: AutoLimit the 
size of ResultSet for a WebUI (or REST) client
URL: https://github.com/apache/drill/pull/1608#discussion_r259682926
 
 

 ##########
 File path: exec/java-exec/src/main/resources/rest/static/js/querySubmission.js
 ##########
 @@ -53,7 +53,18 @@ function doSubmitQueryWithUserName() {
 //Wrap & Submit Query (invoked directly if impersonation is not enabled)
 function wrapAndSubmitQuery() {
     //Wrap if required
-    wrapQuery();
+    var mustWrapWithLimit = $('input[name="forceLimit"]:checked').length > 0;
+    //Clear field when submitting if not mustWrapWithLimit
+    if (!mustWrapWithLimit) {
+      //Wipe out any numeric entry in the field before
+      $('#autoLimit').attr('value', '');
+    } else {
+      let autoLimitValue=document.getElementById("autoLimit").value;
+      if (isNaN(autoLimitValue)) {
+        alert(autoLimitValue+ " is not a number. Please fill in a valid 
number");
 
 Review comment:
   This has been done as part of DRILL-7036 (#1644 )

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to