tustvold opened a new issue #1361: URL: https://github.com/apache/arrow-datafusion/issues/1361
**Describe the bug** `ProjectionExec` does not preserve field metadata when generating the projected schema. I believe this will also cause it to lose dictionary information for the field. I think fixing this will require extending PhysicalExpr with a `fn field(&self, input_schema: &Schema) -> Result<Field>;` or similar to replace the [current logic](https://github.com/apache/arrow-datafusion/blob/0facd4d483e8c289ee4e3a89487d0cd1ede1a110/datafusion/src/physical_plan/projection.rs#L68) that just constructs a new Field **To Reproduce** Create a RecordBatch with a schema with field metadata and pass it through ProjectionExec. **Expected behavior** There is potentially discussion to be had w.r.t schema-level metadata, but I would expect field-level metadata to be preserved for the fields that are projected -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
