You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2021/07/02 05:40:23 UTC

[GitHub] [incubator-pinot] KKcorps commented on a change in pull request #7117: Add timestamp datatype support in JDBC

KKcorps commented on a change in pull request #7117:
URL: https://github.com/apache/incubator-pinot/pull/7117#discussion_r662749542



##########
File path: pinot-clients/pinot-jdbc-client/src/main/java/org/apache/pinot/client/PinotPreparedStatement.java
##########
@@ -33,20 +33,25 @@
 public class PinotPreparedStatement extends AbstractBasePreparedStatement {
 
   private static final String QUERY_FORMAT = "sql";
+  public static final String LIMIT_STATEMENT = "LIMIT";
   private Connection _connection;
   private org.apache.pinot.client.Connection _session;
   private ResultSetGroup _resultSetGroup;
   private PreparedStatement _preparedStatement;
   private String _query;
   private boolean _closed;
   private ResultSet _resultSet;
+  private Integer _maxRows = Integer.MAX_VALUE;
 
   public PinotPreparedStatement(PinotConnection connection, String query) {
     _connection = connection;
     _session = connection.getSession();
-    _query = query;
     _closed = false;
-    _preparedStatement = new PreparedStatement(_session, new Request(QUERY_FORMAT, query));
+    _query = query;
+    if(!_query.contains(LIMIT_STATEMENT)) {

Review comment:
       Yep, compiling the query was my first choice but that is too much overhead for a client side code.




-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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