Skip to content
Raw Markdown

Connect a warehouse or upload DDL

The ontology tells Cassis what your business means; the warehouse supplies the current data. Connect them so Cassis can turn a business question into SQL, run it, and return an answer with real results.

Why Cassis connects to the warehouse

When someone asks a question, Cassis uses the ontology to choose the right definitions, tables, joins, and metrics. It then sends the generated SQL to your warehouse and turns the returned rows into an answer. Your warehouse remains the source of the data; Cassis is the context and query layer in front of it.

Understand the structure
Cassis reads schema metadata such as tables and columns.
Answer from current data
Cassis runs the SQL it generates, so the answer includes result rows rather than SQL alone.
Stay aligned
Cassis detects schema changes that may require an ontology update.

Use a live connection

In project setup, or later under Settings → Database, paste the connection string. Cassis supports PostgreSQL, Snowflake, and BigQuery, detects the SQL dialect from the connection, and stores the credentials encrypted.

When the warehouse schema changes, resync it from the same settings page. Cassis compares the new schema with the previous snapshot and sends affected objects to the review queue instead of rewriting the ontology silently.

Use DDL when live access is not possible

Upload a SQL file containing the schema’s CREATE TABLE statements. Cassis can then understand the structure and generate grounded SQL, but it cannot run that SQL or answer with data. The response includes the SQL and results is null, which is different from a query that ran and returned zero rows.

Upload the file during project setup or under Settings → Database → Update from DDL. When the schema changes, upload the new file again. Cassis shows the same added, removed, and changed objects for review. A pipeline can do this with cassis schema push.

If a statement cannot be parsed, the upload fails and points to the relevant line or table instead of quietly omitting it.

Check the connection

Open the project’s schema view and confirm the expected tables and columns appear. Then ask a test question:

  • With a live warehouse, the answer should include rows and SQL.
  • With DDL only, the answer should include SQL and explain that Cassis did not execute it.

For later schema changes, see Review detected issues.

Cassis on your own warehouse

Running it against your data starts with a conversation about your stack and what you need answered.