https://doris.apache.org/docs/sql-manual/sql-functions/struct-functions/struct
https://doris.apache.org/docs/sql-manual/sql-functions/array-functions/array
您好,根据文档的描述,了解到 struct 和 array
其中 struct 结构已经定义:
查询也正常
select
order_id ,
named_struct('scene',scene,'payment_status',payment_status,'payment_pay_id',payment_pay_id,'payment_refund_id',payment_refund_id) as info
from
parking_ods.ord_order_pay_log
我目前考虑定义这种结构 array<struct<"key1",value1,"key2",value2>>
在原named_struct 结果之外通过array 进行接收,执行结果不正确
select
order_id ,
array(named_struct('scene',scene,'payment_status',payment_status,'payment_pay_id',payment_pay_id,'payment_refund_id',payment_refund_id)) as info
from
parking_ods.ord_order_pay_log
报错信息:
1105 - errCode = 2, detailMessage = No matching function with signature: array(STRUCT).
array 方法的考虑过collect_list 替代,但结果一样的No matching function with signature:
请教各位老师们,selectdb是否支持 struct 列表?或者我的用法不正确