# Connecting a Databricks Source

A Databricks connector imports one shared table using Databricks Open Sharing. Use it for ongoing data that already lives in Databricks.

Your Databricks administrator shares the data, and the Galdera team connects that share to your workspace. Creating a connector in Galdera does not create the share.

## Before you start

* A Galdera organization admin connects the share and tests access (steps 1 and 2 below). After that test succeeds, any member can finish the setup: choose the table, review its columns, and import it. Members can also sync, re-map, and delete imported tables. Testing or removing the connection, and adding another table to a share that already has one, need an admin.
* Ask your Databricks administrator and your Galdera contact to set up the share and recipient details for your workspace. Tell them which schema and tables you want to import.
* Make sure the table has a date column and the numeric values you want to forecast.

If your workspace already has a share connected, an organization admin can use it for another table without repeating this setup.

## Set up the connector

1. Open **Connectors**, find **Databricks** under **Additional connectors**, and click **Connect**.
2. On the connection page, click **Test connection**. If the share is not ready, ask your Databricks administrator and Galdera contact to finish the setup. You can leave and come back later.
3. Once access is verified, click **Add table**. In **Choose data**, select a **Schema**, a **Table**, and a **Start date** for the history to import. The import runs up to today's date. Check the sample preview to confirm you chose the right table.
4. **Review columns**: confirm the date column, choose at least one target measure, and set the data frequency. Review the suggested column roles and answer any questions about the table's layout.
5. **Import**: review the table, history, frequency, and measures, then click **Start import**. Galdera imports the data and applies your column choices.

## Prepared customer data

Where prepared data is enabled for your workspace, the connection page offers a **Data** choice between **Customer share** (the tables shared from your Databricks) and **Prepared customer data** (tables the Galdera team prepared for you). With prepared data, the schema is always `published`: choose a **Table** and check the preview.

You can change this choice until the connector imports data. After that, it keeps reading from the same place; create a new connector to read from the other one.

Prepared data is built from your share, so it needs your share to be working too. If **Test connection** reports a problem with the share, fix the share first.

Prepared data is imported and synced like a shared table. The Galdera team adds new periods to the prepared table over time, and a manual sync imports them (see [Refresh data and add tables](#refresh-data-and-add-tables)). Preparing data never starts a sync on its own, and a sync never starts the preparation.

Prepared tables are meant to grow forward only. If earlier periods change, the next sync re-imports the whole history from the prepared table; if that keeps happening, the connector changes to **Needs review** instead and waits for you to confirm. If columns are added or removed, the connector changes to **Needs review** and doesn't sync until you confirm the mapping on the **Columns** tab. If prepared data is a view over your share, losing access to that share causes imports and syncs to fail.

## Return to an unfinished or completed connector

Galdera saves your setup choices as you go. An unfinished connector reopens at the first step you haven't finished. If an import is already running, the connector shows its progress; you don't need to start it again.

If an import finds no rows, choose an earlier start date and try again. If the data arrives but applying your column choices fails, click **Retry**. Galdera applies the column choices again without rereading the shared table.

## Refresh data and add tables

When setup finishes, open the table to see its status and run history. Galdera doesn't sync sources on a schedule. To refresh data, use the circular-arrow button in the top toolbar (tooltip **Sync**). A refresh button beside the status is labeled **Import again** in **Connectors**, or **Sync now** on other source pages.

To import another table, an organization admin opens the Databricks connection under **Your connections** and clicks **Add table**.
