v.22.7New Feature

Add SQLInsert Output Format

Add SQLInsert output format. Closes #38441. #38477 (Kruglov Pavel).
Added a new SQLInsert output format to ClickHouse.

Why it matters

The SQLInsert output format generates data as INSERT statements, enabling easy export of query results for direct reuse in SQL databases. This solves the problem of manually converting query results into executable INSERT commands, simplifying data migration and backup workflows.

How to use it

Use the new output format by specifying FORMAT SQLInsert at the end of your query. For example:

SELECT * FROM table_name FORMAT SQLInsert