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

Update trino__get_columns_in_relation to use information_schema.columns #444

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

posulliv
Copy link
Member

@posulliv posulliv commented Nov 1, 2024

Overview

We have noticed that queries against information_schema.columns are consistently faster than describe queries. Especially when using the glue catalog with an iceberg connector. For iceberg in particular, there has been particular optimizations made to speed up queries to information_schema.columns (this PR - trinodb/trino#18315).

We've also seen this is faster for JDBC catalogs.

This PR is to query information_schema.columns for getting column information for a relation.

Resolves #443

Checklist

  • I have run this code in development and it appears to resolve the stated issue
  • This PR includes tests, or tests are not required/relevant for this PR
  • README.md updated and added information about my change
  • I have run changie new to create a changelog entry

@posulliv posulliv force-pushed the speed-up-get-columns branch from bb98a04 to 3d38b39 Compare November 1, 2024 20:29
@posulliv posulliv force-pushed the speed-up-get-columns branch from 3d38b39 to ed80b2d Compare November 5, 2024 13:37
@aalbu aalbu requested review from mdesmet and damian3031 November 12, 2024 15:05
Copy link
Member

@mdesmet mdesmet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this contribution! LGTM, can you also run changie and add release notes for this improvement?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

describe on tables can be slower than equivalent query on information_schema.columns
2 participants