xiaokang commented on code in PR #40573:
URL: https://github.com/apache/doris/pull/40573#discussion_r1794521218


##########
be/src/vec/data_types/serde/data_type_time_serde.h:
##########
@@ -41,6 +41,13 @@ class DataTypeTimeSerDe : public 
DataTypeNumberSerDe<Float64> {
                                  int row_idx, bool col_const,
                                  const FormatOptions& options) const override;
 
+    Status write_one_cell_to_json(const IColumn& column, rapidjson::Value& 
result,

Review Comment:
   number -> string



##########
fe/fe-core/src/main/antlr4/org/apache/doris/nereids/DorisParser.g4:
##########
@@ -1708,6 +1709,13 @@ complexColType
     : identifier COLON dataType commentSpec?
     ;
 
+variantSubColTypeList
+    : variantSubColType (COMMA variantSubColType)*
+    ;
+variantSubColType
+    : qualifiedName COLON dataType commentSpec?

Review Comment:
   we can support both.



##########
be/src/vec/functions/function_cast.h:
##########
@@ -882,6 +879,15 @@ struct ConvertImplFromJsonb {
                     res[i] = 0;
                     continue;
                 }
+                if (value->isString()) {
+                    // convert by parse
+                    const auto& data = static_cast<const 
JsonbBlobVal*>(value)->getBlob();
+                    size_t len = static_cast<const 
JsonbBlobVal*>(value)->getBlobLen();
+                    ReadBuffer rb((char*)(data), len);
+                    bool parsed = try_parse_impl<ToDataType>(res[i], rb, 
context);

Review Comment:
   submit pr for other branches to fix jsonb cast



##########
be/src/vec/data_types/serde/data_type_ipv6_serde.h:
##########
@@ -71,6 +71,13 @@ class DataTypeIPv6SerDe : public DataTypeNumberSerDe<IPv6> {
     void write_one_cell_to_jsonb(const IColumn& column, 
JsonbWriterT<JsonbOutStream>& result,
                                  Arena* mem_pool, int unique_id, int row_num) 
const override;
 
+    Status write_one_cell_to_json(const IColumn& column, rapidjson::Value& 
result,

Review Comment:
   number -> string



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

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to