[ 
https://issues.apache.org/jira/browse/DRILL-6753?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16625250#comment-16625250
 ] 

ASF GitHub Bot commented on DRILL-6753:
---------------------------------------

arina-ielchiieva commented on a change in pull request #1477: DRILL-6753: Fix 
show files command to return result the same way as before
URL: https://github.com/apache/drill/pull/1477#discussion_r219710569
 
 

 ##########
 File path: 
exec/java-exec/src/test/java/org/apache/drill/exec/store/ischema/TestFilesTable.java
 ##########
 @@ -86,62 +102,46 @@ public void testSelectWithRecursion() throws Exception {
 
   @Test
   public void testShowFilesWithInCondition() throws Exception {
-    client.testBuilder()
-        .sqlQuery("show files in dfs.`files`")
-        .unOrdered()
-        .sqlBaselineQuery("select * from INFORMATION_SCHEMA.`FILES` where 
schema_name = 'dfs.files'")
-        .go();
+    checkCounts("show files in dfs.`files`",
+        "select * from INFORMATION_SCHEMA.`FILES` where schema_name = 
'dfs.files'");
   }
 
   @Test
-  public void testShowFilesForSpecificFolderSuccess() throws Exception {
+  public void testShowFilesForSpecificDirectory() throws Exception {
     try {
+      client.alterSession(ExecConstants.LIST_FILES_RECURSIVELY, false);
+      QueryBuilder queryBuilder = client.queryBuilder().sql("show files in 
dfs.`files`.folder1");
+      QueryBuilder.QuerySummary querySummary = queryBuilder.run();
+      assertTrue(querySummary.succeeded());
+      assertEquals(2, querySummary.recordCount());
+      // option has no effect
       client.alterSession(ExecConstants.LIST_FILES_RECURSIVELY, true);
-      client.testBuilder()
-          .sqlQuery("show files in dfs.`files`.folder")
-          .unOrdered()
-          .sqlBaselineQuery("select * from INFORMATION_SCHEMA.`FILES` where 
schema_name = 'dfs.files' and relative_path like 'folder/%'")
-          .go();
+      assertTrue(querySummary.succeeded());
 
 Review comment:
   @vvysotskyi nice catch, thanks. Fixed.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


> Fix show files command to return result the same way as before
> --------------------------------------------------------------
>
>                 Key: DRILL-6753
>                 URL: https://issues.apache.org/jira/browse/DRILL-6753
>             Project: Apache Drill
>          Issue Type: Bug
>            Reporter: Arina Ielchiieva
>            Assignee: Arina Ielchiieva
>            Priority: Major
>             Fix For: 1.15.0
>
>
> After DRILL-6680 show files command was returning result the same was as new 
> FILES table. After the changes Drill Explorer cannot browse files since ODBC 
> driver is heavily dependent on previously used column names and types. 
> To do:
> rework show files command result to support previous column names and types.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to