This is an automated email from the ASF dual-hosted git repository.

yiguolei pushed a commit to branch branch-2.1
in repository https://gitbox.apache.org/repos/asf/doris.git


The following commit(s) were added to refs/heads/branch-2.1 by this push:
     new 60ea8ed58d7 branch-2.1: [regression-test](framework) fix 
sql_return_maparray not use alias bug #46674 (#46891)
60ea8ed58d7 is described below

commit 60ea8ed58d7482c54f8d347a8a7b42463da7e0c9
Author: github-actions[bot] 
<41898282+github-actions[bot]@users.noreply.github.com>
AuthorDate: Mon Jan 13 19:33:07 2025 +0800

    branch-2.1: [regression-test](framework) fix sql_return_maparray not use 
alias bug #46674 (#46891)
    
    Cherry-picked from #46674
    
    Co-authored-by: shuke <sh...@selectdb.com>
---
 .../main/groovy/org/apache/doris/regression/suite/Suite.groovy    | 2 +-
 regression-test/suites/manager/test_manager_interface_1.groovy    | 8 +++++++-
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git 
a/regression-test/framework/src/main/groovy/org/apache/doris/regression/suite/Suite.groovy
 
b/regression-test/framework/src/main/groovy/org/apache/doris/regression/suite/Suite.groovy
index b04cb117e01..427cd5d516d 100644
--- 
a/regression-test/framework/src/main/groovy/org/apache/doris/regression/suite/Suite.groovy
+++ 
b/regression-test/framework/src/main/groovy/org/apache/doris/regression/suite/Suite.groovy
@@ -430,7 +430,7 @@ class Suite implements GroovyInterceptable {
         // get all column names as list
         List<String> columnNames = new ArrayList<>()
         for (int i = 0; i < meta.getColumnCount(); i++) {
-            columnNames.add(meta.getColumnName(i + 1))
+            columnNames.add(meta.getColumnLabel(i + 1))
         }
 
         // add result to res map list, each row is a map with key is column 
name
diff --git a/regression-test/suites/manager/test_manager_interface_1.groovy 
b/regression-test/suites/manager/test_manager_interface_1.groovy
index 856cb6802a9..e65ec2e5da3 100644
--- a/regression-test/suites/manager/test_manager_interface_1.groovy
+++ b/regression-test/suites/manager/test_manager_interface_1.groovy
@@ -504,6 +504,12 @@ suite('test_manager_interface_1',"p0") {
         futures.add( thread {
             sleep(1500)
 
+            result = sql """ 
+            select a.*, b.*, c.NAME as WORKLOAD_GROUP_NAME from 
information_schema.active_queries a left join 
+            information_schema.backend_active_tasks b on a.QUERY_ID = 
b.QUERY_ID left join information_schema.workload_groups c on 
a.WORKLOAD_GROUP_ID = c.ID
+            """
+            logger.info("result = ${result}")
+
             result = sql_return_maparray """ 
             select a.*, b.*, c.NAME as WORKLOAD_GROUP_NAME from 
information_schema.active_queries a left join 
             information_schema.backend_active_tasks b on a.QUERY_ID = 
b.QUERY_ID left join information_schema.workload_groups c on 
a.WORKLOAD_GROUP_ID = c.ID
@@ -527,7 +533,7 @@ suite('test_manager_interface_1',"p0") {
                     assertTrue(result[i]["SHUFFLE_SEND_BYTES"].toBigInteger() 
==0) // SHUFFLE_SEND_BYTES     
                     assertTrue(result[i]["SHUFFLE_SEND_ROWS"].toBigInteger() 
==0) // SHUFFLE_SEND_ROWS   
                     assertTrue(result[i]["CURRENT_USED_MEMORY_BYTES"]!=null) 
// CURRENT_USED_MEMORY_BYTES   
-                    assertTrue(result[i]["WORKLOAD_GROUP_ID"]!=null) // 
WORKLOAD_GROUP_NAME              
+                    assertTrue(result[i]["WORKLOAD_GROUP_NAME"]!=null) // 
WORKLOAD_GROUP_NAME              
                 }
             }
             assertTrue(x == 1)


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to