Skip to navigationSkip to main contentSkip to footerScaleway Docs

How to connect to your deployment

This page explains how to connect yourself or your applications to your Data Warehouse for ClickHouse® deployment using the Scaleway console.

To connect your deployment with BI tools, refer to the dedicated documentation.

Before you start

To complete the actions presented below, you must have:

  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 the Actions button in the top-right corner of the page. A drop-down menu displays.

  4. Select Connect using frameworks. The connection wizard displays.

    Note

    To connect your deployment with BI tools, refer to the dedicated documentation.

  5. Select your preferred framework:

    Protocols

    Select the appropriate protocol, then run the displayed command in a terminal. Remember to replace the placeholders with the appropriate values, and to specify the correct path to the certificate file.

    clickhouse client \
    --host <YOUR_DEPLOYMENT_ID>.dtwh.<REGION>.scw.cloud \
    --port 9440 \
    --secure \
    --user scwadmin \
    --password '<PASSWORD>'

    Languages

    Select the desired language, then run the code displayed to create a file that connects to your deployment, and run queries programmatically. Remember to replace the placeholders with the appropriate values, and to specify the correct path to the certificate file.

    pip install clickhouse-connect
    cat <<EOF >clickhouse.py
    import clickhouse_connect
    
    client = clickhouse_connect.get_client(
        host="<YOUR_DEPLOYMENT_ID>.dtwh.<REGION>.scw.cloud",
        port=443,
        username="scwadmin",
        password="<PASSWORD>",
    )
    query_result = client.query("SELECT 1")
    print(query_result.result_set)
    EOF
    python clickhouse.py

You are now connected to your Data Warehouse for ClickHouse® deployment using the administrator account.

Still need help?

Create a support ticket
No Results