Skip to content

Instantly share code, notes, and snippets.

@muthugit
Created September 2, 2021 06:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save muthugit/8f87245740f46ab8f880b852b1b77740 to your computer and use it in GitHub Desktop.
Save muthugit/8f87245740f46ab8f880b852b1b77740 to your computer and use it in GitHub Desktop.
Clickhouse Copy data from one database engine to another engine
clickhouse-client --host <sourceIP> --password <password> --database <source_db> \
--query="select * from <source table> FORMAT Native" | \
clickhouse-client --user default --password <local db password> --database <local database> \
--query="insert into <local table name> FORMAT Native"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment