v.19.3Improvements
Table Index Size Is Not Accounted for Memory Limits When Doing ATTACH TABLE Query
Table index size is not accounted for memory limits when doing ATTACH TABLE query. Avoided the possibility that a table cannot be attached after being detached. #4396 (alexey-milovidov)Why it matters
Before this change, the memory used by a table's index was not considered when executing theATTACH TABLE command, which could cause the operation to fail if the available memory was insufficient. This feature ensures the index size is included in memory calculations to reliably attach detached tables without running into memory limit issues.How to use it
The feature is applied automatically in theATTACH TABLE command; no additional user configuration is required. When you detach and then attach a table, ClickHouse now accounts for the index size to ensure successful attachment.