Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Manifests table scan should return iceberg schema rather arrow schema #868

Open
liurenjie1024 opened this issue Jan 3, 2025 · 4 comments · May be fixed by #871
Open

Manifests table scan should return iceberg schema rather arrow schema #868

liurenjie1024 opened this issue Jan 3, 2025 · 4 comments · May be fixed by #871
Labels
bug Something isn't working

Comments

@liurenjie1024
Copy link
Contributor

          I think we should return iceberg schema here, and user could easily convert it to arrow schema.

Originally posted by @liurenjie1024 in #861 (comment)

@liurenjie1024 liurenjie1024 added the bug Something isn't working label Jan 3, 2025
@Xuanwo
Copy link
Member

Xuanwo commented Jan 3, 2025

Makes sense to me.

@flaneur2020
Copy link
Contributor

👍 let me fix this

@rshkv
Copy link
Contributor

rshkv commented Jan 8, 2025

Also happy to help with this but not sure why / if we want this.

Looking at the DataFusion integration, it seems useful for the metadata TableProvider to be able to provide the Arrow schema.

If we need to expose the Arrow schema for 1) the DataFusion integration and 2) to build RecordBatch internally, it might be preferable for the metadata tables to have schema() return Arrow. If necessary, clients can still convert to Iceberg. Unlike the other way round, where we know conversion would be necessary.

@liurenjie1024
Copy link
Contributor Author

The reason I suggest returning iceberg schema is that metadata table is a concept in iceberg library, not only in datafusion integration. The difference is that, iceberg library will be used by more engines like datafuse, polars, etc. The reason we provide an record batch stream is for convenience, IMO we should provid similar plan files api so that other engines could consume it, but since arrow is the defact standard for in memory data exchange, I'm fine with keeping the scan api.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants