Skip to main content

Connecting Astrato to ClickHouse

Astrato uses Pushdown SQL to query ClickHouse Cloud or on-premise deployments directly. This means you can access all of the data you need, powered by the industry-leading performance of ClickHouse.

Connection data required

When setting up your data connection, you'll need to know:

  • Data connection: Hostname, Port

  • Database Credentials: Username, Password

To connect to ClickHouse with HTTP(S) you need this information:

  • The HOST and PORT: typically, the port is 8443 when using TLS or 8123 when not using TLS.

  • The DATABASE NAME: out of the box, there is a database named default, use the name of the database that you want to connect to.

  • The USERNAME and PASSWORD: out of the box, the username is default. Use the username appropriate for your use case.

The details for your ClickHouse Cloud service are available in the ClickHouse Cloud console. Select the service that you will connect to and click Connect:

ClickHouse Cloud service connect button

Choose HTTPS, and the details are available in an example curl command.

ClickHouse Cloud HTTPS connection details

If you are using self-managed ClickHouse, the connection details are set by your ClickHouse administrator.

Creating the data connection to ClickHouse

  • Select Data in the sidebar, and select the Data Connection tab (or, navigate to this link: https://app.astrato.io/data/sources) ​
  • Click on the New Data Connection button in the top right side of the screen.
Astrato Data Connection
  • Select ClickHouse.

    Astrato ClickHouse Data Connection
  • Complete the required fields in the connection dialogue box

Astrato connect to ClickHouse required fields
  • Click Test Connection. If the connection is successful, give the data connection a name and click Next.

  • Set the user access to the data connection and click connect.

    Astrato connect to ClickHouse User Access
  • A connection is created and a dataview is created.

Note

if a duplicate is created, a timestamp is added to the data source name.

Creating a semantic model / data view

In our Data View editor, you will see all of your Tables and Schemas in ClickHouse, select some to get started.

Astrato connect to ClickHouse User Access

Now that you have your data selected, go to define the data view. Click define on the top right of the webpage.

In here, you are able to join data, as well as, create governed dimensions and measures - ideal for driving consistency in business logic across various teams.

Astrato connect to ClickHouse User Access

Astrato intelligently suggests joins using your meta data, including leveraging the keys in ClickHouse. Our suggested joins make it easy for you to gets started, working from your well-governed ClickHouse data, without reinventing the wheel. We also show you join quality so that you have the option to review all suggestions, in detail, from Astrato.


Astrato connect to ClickHouse User Access

Creating a dashboard

In just a few steps, you can build your first chart in Astrato.

  1. Open visuals panel
  2. Select a visual (lets start with Column Bar Chart)
  3. Add dimension(s)
  4. Add measure(s)
Astrato connect to ClickHouse User Access

View generated SQL supporting each visualization

Transparency and accuracy are at the heart of Astrato. We ensure that every query generated is visible, letting you keep full control. All compute happens directly in ClickHouse, taking advantage of its speed while maintaining robust security and governance.

Astrato connect to ClickHouse User Access

Example completed dashboard

A beautiful complete dashboard or data app isn't far away now. To see more of what we've built, head to our demo gallery on our website. https://astrato.io/gallery

Astrato connect to ClickHouse User Access