Or you can right a UDF by yourself, if you encouter an null value you can just 
return null and in outer you can filter out the null values.

Best,
Danny Chan
在 2019年3月21日 +0800 AM2:45,Shahar Cizer Kobrinsky 
<[email protected]>,写道:
> Hey All,
>
> New to Calcite, trying to express a select statement in SQL where i build a
> map.
> The thing is i want to conditionally add items to it, so for example have
> key 'c' with value from column 'c' only if the value is not null
>
> SELECT a,b, map['c',c, 'd', d] as my_map FROM...
>
> Is there a way to conditionally have key/values in the map?
>
> Thanks!
> Shahar

Reply via email to