Re: Backporting array_agg from 1.20 to 1.18

2024-10-24 Thread Jiabao Sun
Hi Daniele, It's a good idea to implement a UDF[1] by referring to the ArrayAggFunction[2] in Flink. I don't understand what "I don't get how RowData comes into play" means. Could you clarify it? Best, Jiabao [1] https://nightlies.apache.org/flink/flink-docs-master/docs/dev/table/functions/

Re: Backporting array_agg from 1.20 to 1.18

2024-10-24 Thread Daniele Parmeggiani
Hi Jiabao 👋 Sorry, I phrased it incorrectly. I'm new to Flink, so I just don't know what RowData is essentially. Daniele On October 24, 2024, Jiabao Sun wrote: > Hi Daniele, > > It's a good idea to implement a UDF[1] by referring to the > ArrayAggFunction[2] in Flink. > > I don't understand wh

Re: Backporting array_agg from 1.20 to 1.18

2024-10-24 Thread Daniele Parmeggiani
Hi Hanyu Zheng 👋 I've actually included the function into a UDF jar, hoping I could get away with not forking Flink itself. Do you think that'll work? In my SQL script I import the function like this: ```sql create temporary function ArrayAggFunction     as 'eu.spaziodati.cp.flink.funcs.ArrayAggF

Re: Backporting array_agg from 1.20 to 1.18

2024-10-23 Thread Hanyu (Peter) Zheng via user
Hi Daniele Parmeggiani, I have some ideas regarding the issue. From the exception: java.lang.ClassCastException: class org.apache.flink.types.Row cannot be cast to class org.apache.flink.table.data.RowData This error clearly indicates that the code is trying to cast a Row object to a RowData obje

RE: Backporting array_agg from 1.20 to 1.18

2024-10-23 Thread Hanyu (Peter) Zheng via user
I have some ideas. -- [image: Confluent] Hanyu (Peter) Zheng he/him/his Software Engineer +1 (213) 431-7193 <+1+(213)+431-7193> Follow us: [image: Blog]