dvjyothsna commented on a change in pull request #1748: DRILL-7171: Create
metadata directories cache file in the leaf level directories to support
ConvertCountToDirectScan optimization.
URL: https://github.com/apache/drill/pull/1748#discussion_r275204056
##########
File path:
exec/java-exec/src/test/java/org/apache/drill/exec/planner/logical/TestConvertCountToDirectScan.java
##########
@@ -274,4 +274,39 @@ public void testCountsWithWildCard() throws Exception {
test("drop table if exists %s", tableName);
}
}
+
+ @Test
+ public void testCountsForLeafDirectories() throws Exception {
+ test("use dfs.tmp");
+ String tableName = "parquet_table_counts";
+
+ try {
+ test(String.format("create table `%s/1` as select * from
cp.`tpch/nation.parquet`", tableName));
+ test(String.format("create table `%s/2` as select * from
cp.`tpch/nation.parquet`", tableName));
+ test(String.format("create table `%s/3` as select * from
cp.`tpch/nation.parquet`", tableName));
+
+ test("refresh table metadata %s", tableName);
+
+ String sql = String.format("select\n" +
Review comment:
This can't be changed because the table name is provided as a variable.
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services