**Use case**

ClickHouse already throws exception if the data for INSERT is empty:

```
Code: 108. DB::Exception: No data to insert
```

Let's introduce a setting, enabled by default, to control this behavior.
The user will be able to disable it to allow empty INSERTs.

This is useful in some batch scripts.
e.addMessage("data for INSERT was parsed from query"
            throw;
        }
        // Remember where the data ended. We use this info later to determine
        // where the next query begins.
         parsed_insert_query->data + data_in.count(
    }
    else if (!is_interactive)
    {
        if (need_render_progress)
        {
            /// Add callback to track reading from fd.
            std_in.setProgressCallback(global_context
        }
        /// Send data read from stdin.
        try
        {
            sendDataFrom(std_in, sample, columns_description_for_query, parsed_query
        }
        catch (Exception & e)
        {
            e.addMessage("data for INSERT was parsed from stdin"
            throw;
        }
    }
    else
        throw Exception("No data to insert", ErrorCodes::NO_DATA_TO_INSERT
}
void ClientBase::sendDataFrom(ReadBuffer & buf, Block & sample, const ColumnsDescription & columns_description, ASTPtr parsed_query)
{