ajantha-bhat commented on a change in pull request #3913:
URL: https://github.com/apache/carbondata/pull/3913#discussion_r486048413



##########
File path: 
integration/presto/src/main/prestodb/org/apache/carbondata/presto/CarbondataSplitManager.java
##########
@@ -117,6 +122,16 @@ public ConnectorSplitSource 
getSplits(ConnectorTransactionHandle transactionHand
       // file metastore case tablePath can be null, so get from location
       location = table.getStorage().getLocation();
     }
+    List<PartitionSpec> filteredPartitions = new ArrayList<>();
+    if (layout.getPartitionColumns().size() > 0 && 
layout.getPartitions().isPresent()) {
+      List<String> colNames =
+          layout.getPartitionColumns().stream().map(x -> ((HiveColumnHandle) 
x).getName())
+              .collect(Collectors.toList());
+      for (HivePartition partition : layout.getPartitions().get()) {
+        filteredPartitions.add(new PartitionSpec(colNames,

Review comment:
       ```
   presto:redods> select dtm,hh from dw_log_ubt_partition_carbon_neww;
        dtm     |     hh
   -------------+------------
    part_dtm_01 | part_hh_01
    part_dtm_01 | part_hh_01
    part_dtm_01 | part_hh_02
    part_dtm_20 | part_hh_21
    part_dtm_01 | part_hh_03
    part_dtm_21 | NULL
   (6 rows)
   
   Query 20200910_035416_00017_wv9qh, FINISHED, 3 nodes
   Splits: 22 total, 22 done (100.00%)
   0:01 [6 rows, 176B] [9 rows/s, 282B/s]
   
   presto:redods> select dtm,hh from dw_log_ubt_partition_carbon_neww where 
(dtm = 'part_dtm_01' and hh = 'part_hh_03') or dtm='part_dtm_21';
        dtm     |     hh
   -------------+------------
    part_dtm_01 | part_hh_03
    part_dtm_21 | NULL
   (2 rows)
   
   Query 20200910_035548_00018_wv9qh, FINISHED, 3 nodes
   Splits: 18 total, 18 done (100.00%)
   0:01 [2 rows, 0B] [1 rows/s, 0B/s]
   
   
   ```




----------------------------------------------------------------
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


Reply via email to