Attach filesAttach ScreenshotAdd voteVotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments


    • Type: Sub-task
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 1.7.1
    • Fix Version/s: None
    • Component/s: api


      KuduScannerBuild API only supports the build of a scan using predicates in a conjuctive operation.
      Meaning that when using more than one predicate (p1,p2), the scan will be done using a statement similar to:

      WHERE p1 AND p2;


      In Java code:

      kc = new KuduClient.KuduClientBuilder(kuduMasters).build();
      session = kc.newSession();
      KuduScanner ks = kc.newScannerBuilder(table).addPredicate(p1).addPredicate(p2).build();


      There is no possibility to specify a OR operation that applies an disjunction between all/some predicates. E.g.

      WHERE p1 OR p2;



      The only way to do this using the current API (1.7.1) is to use two (or more) scanners and iterate them separately:


      KuduScanner scanner1 = kc.newScannerBuilder(table).addPredicate(p1).build();
      KuduScanner scanner2 = kc.newScannerBuilder(table).addPredicate(p2).build();
      while (scanner1.hasMoreRows()) {
          RowResultIterator results = scanner1.nextRows();
          while (results.hasNext()) {
              RowResult rowData =;
              //Do stuff with rowData
      while (scanner2.hasMoreRows()) {
          RowResultIterator results = scanner2.nextRows();
          while (results.hasNext()) {
              RowResult rowData =;
              //Do stuff with rowData


      Kudu API should provide "almost" the same query processing power as IMPALA or an SQL engine.
      Programmers should rely on Kudu API to operations like these and others like: sorting, table joins, etc.


        Issue Links



            • Assignee:
              ZhangYao ZhangYao
              RikG Ricardo Gaspar


              • Created:

                Issue deployment