Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support to set ClickHouse insert settings when writing to a table #369

Open
mzitnik opened this issue Nov 11, 2024 · 0 comments
Open

Support to set ClickHouse insert settings when writing to a table #369

mzitnik opened this issue Nov 11, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@mzitnik
Copy link
Collaborator

mzitnik commented Nov 11, 2024

We can add custom settings to ClickHouse SQL when running an insert.

Example:
INSERT INTO [table] SETTINGS [...]

Currently, there is no way to achieve this with the spark connector.

Maybe spark-clickhouse-connector can read settings starting with spark.clickhouse.write.settings. and apply them when write into clickhouse tables.

@mzitnik mzitnik added the enhancement New feature or request label Nov 11, 2024
mahdimalverdi pushed a commit to mahdimalverdi/spark-clickhouse-connector that referenced this issue Dec 21, 2024
- Enable custom ClickHouse insert settings when writing to tables.
- Add support for `spark.clickhouse.write.settings.*` configuration.
- Ensure settings are applied to the `INSERT INTO ... SETTINGS ...` SQL command.
- Update documentation to describe usage of write settings.
- Add unit tests to validate behavior.

Closes ClickHouse#369
mahdimalverdi pushed a commit to mahdimalverdi/spark-clickhouse-connector that referenced this issue Dec 21, 2024
- Enable custom ClickHouse insert settings when writing to tables.
- Add support for `spark.clickhouse.write.settings` configuration.
- Update documentation to describe usage of write settings.

Closes ClickHouse#369
mahdimalverdi pushed a commit to mahdimalverdi/spark-clickhouse-connector that referenced this issue Dec 21, 2024
mahdimalverdi added a commit to mahdimalverdi/spark-clickhouse-connector that referenced this issue Dec 21, 2024
* Update configurtion file (ClickHouse#372)

* Support ClickHouse insert settings for table writes (ClickHouse#369)

- Enable custom ClickHouse insert settings when writing to tables.
- Add support for `spark.clickhouse.write.settings.*` configuration.
- Ensure settings are applied to the `INSERT INTO ... SETTINGS ...` SQL command.
- Update documentation to describe usage of write settings.
- Add unit tests to validate behavior.

Closes ClickHouse#369

* Support ClickHouse insert settings for table writes (ClickHouse#369)

- Enable custom ClickHouse insert settings when writing to tables.
- Add support for `spark.clickhouse.write.settings` configuration.
- Update documentation to describe usage of write settings.

Closes ClickHouse#369

* reformat the codes

Closes ClickHouse#369

---------

Co-authored-by: Mark Zitnik <[email protected]>
Co-authored-by: Mahdi Malverdi <[email protected]>
mahdimalverdi pushed a commit to mahdimalverdi/spark-clickhouse-connector that referenced this issue Dec 21, 2024
- Enable custom ClickHouse insert settings when writing to tables.
- Add support for `spark.clickhouse.write.settings` configuration.
- Update documentation to describe usage of write settings.

Closes ClickHouse#369
mahdimalverdi pushed a commit to mahdimalverdi/spark-clickhouse-connector that referenced this issue Dec 21, 2024
mahdimalverdi added a commit to mahdimalverdi/spark-clickhouse-connector that referenced this issue Dec 21, 2024
* Support ClickHouse insert settings for table writes (ClickHouse#369)

- Enable custom ClickHouse insert settings when writing to tables.
- Add support for `spark.clickhouse.write.settings` configuration.
- Update documentation to describe usage of write settings.

Closes ClickHouse#369

* reformat the codes

Closes ClickHouse#369

---------

Co-authored-by: Mahdi Malverdi <[email protected]>
mahdimalverdi pushed a commit to mahdimalverdi/spark-clickhouse-connector that referenced this issue Dec 21, 2024
- Enable custom ClickHouse insert settings when writing to tables.
- Add support for `spark.clickhouse.write.settings` configuration.
- Update documentation to describe usage of write settings.

Closes ClickHouse#369
mahdimalverdi pushed a commit to mahdimalverdi/spark-clickhouse-connector that referenced this issue Dec 21, 2024
mahdimalverdi added a commit to mahdimalverdi/spark-clickhouse-connector that referenced this issue Dec 21, 2024
* Support ClickHouse insert settings for table writes (ClickHouse#369)

- Enable custom ClickHouse insert settings when writing to tables.
- Add support for `spark.clickhouse.write.settings` configuration.
- Update documentation to describe usage of write settings.

Closes ClickHouse#369

* reformat the codes

Closes ClickHouse#369

---------

Co-authored-by: Mahdi Malverdi <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
1 participant