You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@calcite.apache.org by Yang Zhang <ya...@linkedin.com> on 2019/09/19 21:14:23 UTC

Flatten SQL result, why is it required and how to get the result recovered

Hello Calcite team,

In terms of query involving nested field (select * from a table scan containing nested fields), I saw Calcite would flatten the result (https://github.com/apache/calcite/blob/037250b99d6db8a605b64780a3643f784d07d308/core/src/main/java/org/apache/calcite/prepare/PlannerImpl.java#L314). Why is this required? And how can flatten result be recovered back to nested row? Thank you!

Best,
Yang