kishoreg commented on a change in pull request #4216: PQL -> SQL enhancement - 
phase 1 - new Pinot Query Struct
URL: https://github.com/apache/incubator-pinot/pull/4216#discussion_r292169448
 
 

 ##########
 File path: 
pinot-common/src/main/java/org/apache/pinot/pql/parsers/pql2/ast/SelectAstNode.java
 ##########
 @@ -144,4 +149,27 @@ public void updateBrokerRequest(BrokerRequest 
brokerRequest) {
       brokerRequest.setSelections(null);
     }
   }
+
+  @Override
+  public void updatePinotQuery(PinotQuery pinotQuery) {
+    // Set data source
+    DataSource dataSource = new DataSource();
+    dataSource.setTableName(_resourceName);
+    pinotQuery.setDataSource(dataSource);
+    sendPinotQueryUpdateToChildren(pinotQuery);
+    if (_recordLimit != -1) {
 
 Review comment:
   I want to keep the behavior similar to what we have currently. This will 
help us in writing that generic validate/compare method. The existing code 
looks like this. 
   
   ```  if (selections != null) {
         if (_recordLimit != -1) {
           selections.setSize(_recordLimit);
         } else {
           // Pinot quirk: default to LIMIT 10
           selections.setSize(10);
         }
         if (_offset != -1) {
           selections.setOffset(_offset);
         }
       }```

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org

Reply via email to