v.21.3Improvement

Add Conversion of Block Structure for INSERT into Distributed Tables

Add conversion of block structure for INSERT into Distributed tables if it does not match. #19947 (Azat Khuzhin).
Adds automatic conversion of data block structure during INSERT operations into Distributed tables when the structure does not match the expected format.

Why it matters

This feature solves the problem of INSERT failures caused by mismatched block structures when writing to Distributed tables. It improves usability by enabling seamless data insertion without requiring manual data structure adjustments, thus reducing errors and simplifying data loading workflows.

How to use it

Users do not need to take any explicit action to enable this feature. When performing an INSERT into a Distributed table, ClickHouse will automatically convert the data block structure to match the expected format if it detects any mismatch.