Skip to navigationSkip to main contentSkip to footerScaleway Docs

How to import data into a Data Warehouse for ClickHouse® deployment

Data federation allows you to query and combine data from multiple sources, enabling seamless analytics across different databases or storage systems without the need to move or duplicate data.

Scaleway Data Warehouse for ClickHouse® allows you to quickly import any type of compatible data into bottomless storage with minimal configuration.

Before you start

To complete the actions presented below, you must have:

How to import data using the ClickHouse® CLI

Connecting to the ClickHouse® CLI

  1. Click ClickHouse® under Data & Analytics on the side menu. The Data Warehouse deployment page displays.

  2. Click the name of the Data Warehouse deployment you want to connect to. The overview tab of the deployment displays.

  3. Click Connect next to Frameworks in the Connect to your deployment section. The connection wizard displays.

  4. Select Protocols, then copy the command in the ClickHouse® CLI tab.

  5. In a terminal, paste and execute the copied command to connect to your deployment. Make sure to replace the placeholders with the corresponding values.

    clickhouse client \
    --host <YOUR_DEPLOYMENT_URL> \
    --port 9440 \
    --secure \
    --user scwadmin \
    --password '<YOUR_DEPLOYMENT_PASSWORD>'
  6. You are now connected to your deployments using the ClickHouse® CLI, you can now import data.

Tip

You can connect to your deployment using the ClickHouse® HTTP console directly from the Overview tab.

Importing data into your deployment from an Object Storage bucket

There are several ways to import data into your Data Warehouse for ClickHouse® deployment, depending on how your data is stored. One of the most common ways is to import it from an Object Storage bucket in any format supported by ClickHouse®.

The s3 table function reads data directly from an Object Storage bucket by specifying the URL of the bucket, the file format, and the data structure.

INSERT INTO your_table
SELECT *
FROM s3('https://my-bucket.s3.scaleway.com/data/my_data.csv', 'CSV', 'column1 String, column2 Int32')
Still need help?

Create a support ticket
No Results