You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by mo...@apache.org on 2022/02/14 01:28:43 UTC

[incubator-doris] branch master updated: [fix](fe-ui)Solve the problem that the web UI playground preview table data, the field is the wrong problem (#8016)

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

morningman pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-doris.git


The following commit(s) were added to refs/heads/master by this push:
     new 969cd0c  [fix](fe-ui)Solve the problem that the web UI playground preview table data, the field is the wrong problem (#8016)
969cd0c is described below

commit 969cd0c39164ed8258326bbfa5a4f114df28a1d8
Author: jiafeng.zhang <zh...@gmail.com>
AuthorDate: Mon Feb 14 09:28:32 2022 +0800

    [fix](fe-ui)Solve the problem that the web UI playground preview table data, the field is the wrong problem (#8016)
    
    Solve the problem that the web UI playground preview table data, the field is the wrong problem
---
 .../main/java/org/apache/doris/httpv2/util/StatementSubmitter.java | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/fe/fe-core/src/main/java/org/apache/doris/httpv2/util/StatementSubmitter.java b/fe/fe-core/src/main/java/org/apache/doris/httpv2/util/StatementSubmitter.java
index ae51fb8..1c0b979 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/httpv2/util/StatementSubmitter.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/httpv2/util/StatementSubmitter.java
@@ -172,7 +172,12 @@ public class StatementSubmitter {
                 List<Object> row = Lists.newArrayListWithCapacity(colNum);
                 // index start from 1
                 for (int i = 1; i <= colNum; ++i) {
-                    row.add(rs.getObject(i));
+                    String type = rs.getMetaData().getColumnTypeName(i);
+                    if("DATE".equalsIgnoreCase(type) || "DATETIME".equalsIgnoreCase(type)){
+                        row.add(rs.getString(i));
+                    } else {
+                        row.add(rs.getObject(i));
+                    }
                 }
                 rows.add(row);
                 rowCount++;

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