{{ message }}
Added index_length column to information_schema.tables#78119
Merged
Conversation
Contributor
729fdd0 to
b2ca555
Compare
system.tables and information_schema.tables
system.tables and information_schema.tablesindex_length column to system.tables and information_schema.tables
rschu1ze
reviewed
Mar 24, 2025
Member
There was a problem hiding this comment.
No need to change anything in C++, all existing data can be gathered from fields
primary_key_size
marks_bytes
secondary_indices_compressed_bytes
secondary_indices_uncompressed_bytes
secondary_indices_marks_bytes
in system.parts.
Contributor
Author
There was a problem hiding this comment.
Fair enough. I looked at how the information_schema views are defined, and they all are simple select queries, so I thought that was the desired effect.
b2ca555 to
4a9a5f5
Compare
index_length column to system.tables and information_schema.tablesindex_length column to information_schema.tables
4a9a5f5 to
9e9148f
Compare
This comment was marked as resolved.
This comment was marked as resolved.
jsc0218
reviewed
Mar 26, 2025
This column is the computed sum of: - compressed size of the primary index - sum of all marks - compressed size of all secondary indexes and their marks The goal is to improve MySQL compatibility: https://dev.mysql.com/doc/refman/8.4/en/information-schema-tables-table.html Tests that touch the information_schema.tables have been adjusted: - 01161_information_schema - 02206_information_schema_show_database - test_from_system_tables.py Fixes ClickHouse#57590
9e9148f to
86f260b
Compare
This comment was marked as resolved.
This comment was marked as resolved.
rschu1ze
approved these changes
Mar 27, 2025
Member
|
Let's see what CI says (it is unfortunately quite unstable at the moment). |
Contributor
This was referenced Apr 3, 2026
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Resolves #57590
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):
Added column
index_length_columntoinformation_schema.tablesfor better compatibility with MySQL.