[Kibana canvas] group multiple columns into one column with sql


This is the request i want to do :

select value from
    select sum(field1) as value from MyIndex
    select sum(field2) as value from MyIndex
    select sum(field3) as value from MyIndex
) test 

however, I have this issue :


the objectif ofthe request is to generate a Pie chart splited accroding the column generated.

Thanks !

union is not supported in Elasticsearch SQL. There's an issue already for that - https://github.com/elastic/elasticsearch/issues/34414 - but it's not on the roadmap.