# MariaDB Add a MariaDB Enrichment Datastore

Source: https://userguide.qualytics.io/source-datastore/datastore/jdbc/maria-db/how-tos/add-enrichment/

An **enrichment datastore** is where Qualytics writes its findings: scan results, source record examples, remediation snapshots, materialized copies, and exports. Keep it on a dedicated schema or storage path, separate from the source data you govern. When a source datastore is linked to it, that source's writes land there. The destination can share the source's connection when those credentials have the required write access.

To use a MariaDB datastore as a destination, its connection user needs the write grants listed under [Additional Permissions for an Enrichment Datastore](https://userguide.qualytics.io/source-datastore/datastore/jdbc/maria-db/permissions/#additional-permissions-for-enrichment-destination). Then link it from the datastore that will write to it: open its **Settings**  menu, click **Enrichment** , and either pick the MariaDB datastore under **Use existing** or create it there under **Add new**. The second step of the Add Datastore page offers the same choice through a selector: **Existing Destination** picks a datastore already set up, while **Existing Connection** and **New Connection** create one. The flow is the same for every connector and is documented once, in [Link an Enrichment Destination](https://userguide.qualytics.io/source-datastore/enrichment-datastore/how-tos/link-enrichment/) and [Link Enrichment on Datastore Creation](https://userguide.qualytics.io/source-datastore/enrichment-datastore/how-tos/link-during-creation/).

The rest of this page covers only what is specific to MariaDB: the fields you fill in when creating the destination on MariaDB from inside that dialog. For what Qualytics writes and how the outputs are named, see [Enrichment Outputs](https://userguide.qualytics.io/source-datastore/enrichment-datastore/deep-dive/tables/).

## Field reference

The **Enrichment Destination** step shows the sections below when MariaDB is selected. When reusing an existing connection, the **Connection Properties** section, with its **Secrets Management** and **Advanced** groups, comes already filled in and read-only.

### Connection Properties

These fields define the MariaDB server Qualytics connects to and the account it connects with, in the order the form shows them. They are the same fields as on the source datastore flow, repeated here so this section stands on its own.

| Field | Required | Type | Description |
| --- | --- | --- | --- |
| **Connection Name** | Yes | Text | A label for the saved connection (e.g., `acme_mariadb_enrichment`), so other datastores can reuse it later. |
| **HashiCorp Vault** | No | Toggle | Sits in the collapsed **Secrets Management** group, right below **Connection Name**. Turn it on to pull credentials from a secrets manager instead of typing them into the form; it shows the six fields below. Despite the label, any secrets manager that exposes a compatible REST API works, not only HashiCorp Vault; see [HashiCorp Vault](https://userguide.qualytics.io/source-datastore/datastore/deep-dive/hashicorp-vault/). |
| **Login URL** | Yes | Text | Shown when **HashiCorp Vault** is on. The full URL of the login endpoint (e.g., `https://vault.example.com/v1/auth/approle/login`). With Vault namespaces, add the namespace after `/v1/`, as in `/v1/<namespace>/auth/approle/login`. |
| **Credentials Payload** | Yes | Text | Shown when **HashiCorp Vault** is on. A JSON body containing the credentials Vault expects (e.g., `{"role_id":"...","secret_id":"..."}`). |
| **Token JSONPath** | Yes | Text | Shown when **HashiCorp Vault** is on. The JSONPath that extracts the client token from Vault's response. Defaults to `$.auth.client_token`. |
| **Secret URL** | Yes | Text | Shown when **HashiCorp Vault** is on. The full URL of the secret, including `https://` and the host (e.g., `https://vault.example.com/v1/secret/data/mariadb`). With Vault namespaces, add the namespace after `/v1/`. |
| **Token Header Name** | Yes | Text | Shown when **HashiCorp Vault** is on. The HTTP header name used to send the token. Defaults to `X-Vault-Token`. |
| **Data JSONPath** | Yes | Text | Shown when **HashiCorp Vault** is on. The JSONPath that extracts the key/value pairs from Vault's response. Use `$.data.data` for a KV version 2 secret (its API path contains `/data/`) and `$.data` for KV version 1 or the database secrets engine. The form pre-fills `$.data`. |
| **Host** | Yes | Text | The hostname or address of the MariaDB server. |
| **Port** | Yes | Number | The port the MariaDB instance listens on. Defaults to `3306`. |
| **User** | Yes | Text | The MariaDB account Qualytics connects as. |
| **Password** | Yes | Text | The password for that account. |

> **Note**
>
> Reference a key from the secret in any **Connection Properties** or **Authentication** field with `${key}`, for example `${password}`. Write it with braces (`${key}`, never `$.key`) and match the key name's case. Qualytics resolves it each time the connection is opened, so a changed value takes effect on the next connection. Setup steps, the namespace rule, and a troubleshooting page are on the [HashiCorp Vault](https://userguide.qualytics.io/source-datastore/datastore/deep-dive/hashicorp-vault/) pages.

### Advanced

A collapsed group at the end of **Connection Properties**, below **Password**. It also belongs to the connection.

| Field | Required | Type | Description |
| --- | --- | --- | --- |
| **Max Parallelization** | No | Number | Caps how many queries Qualytics runs at the same time against a datastore reached through this connection, from 1 to 100. Leave it empty for no explicit limit. The cap applies per datastore, so datastores sharing this connection each get their own allowance. See [Max Parallelization](https://userguide.qualytics.io/source-datastore/datastore/deep-dive/connection/#max-parallelization). |

### Location

Where Qualytics writes the enrichment tables.

| Field | Required | Type | Description |
| --- | --- | --- | --- |
| **Database** | Yes | Option | The database Qualytics writes the enrichment tables into. Pick exactly one, and make sure the account has write access to it. |

> **Warning**
>
> The account used by an enrichment datastore needs read and write access, while a source datastore needs only read access.

### General

| Field | Required | Type | Description |
| --- | --- | --- | --- |
| **Name** | Yes | Text | The name of the new datastore. |
| **Teams** | Yes | Option | Select one or more teams to associate with the datastore. |

> **Note: Table prefix**
>
> Qualytics names the Scan, Remediation, and Materialize outputs with a **Prefix**, and each source sharing a destination needs a unique one. Export tables use the normalized datastore name instead. Where you set the prefix depends on where you link the destination:
>
> - **Enrichment Destination dialog**: **Prefix** is a required field at the top of the dialog, already filled in from the datastore's name (or with its current prefix). Change it there before you click **Save**.
> - **Second step of the Add Datastore page**: Qualytics generates the prefix from the source datastore's name. To change it before creating the datastore, click **Edit prefixes**  in the **Prefix** section of this step.

### Write Behavior

Whether Qualytics profiles the written tables after each write, and whether a Scan also writes a snapshot of the anomalous records. Both appear below the destination under **After each write**, in this order. When you create a new destination in the second step of the Add Datastore page, they sit in a group named **Write Behavior**.

| Field | Required | Type | Description |
| --- | --- | --- | --- |
| **Profile written tables in the enrichment destination** | No | Toggle | On by default. After this datastore writes to the destination, Qualytics always adds the written outputs to the destination, names them, and links them to their source. With this on, Qualytics also profiles them, which types their fields and records row counts, so they are ready to use without a manual step. |
| **Remediation Strategy** | No | Choice | Controls whether and how anomalous source records are written to the enrichment destination. **None** does not write them and is the default, **Append** adds the anomalous records after each scan, and **Overwrite** keeps only the records from the latest scan. |

## Steps

Fill in these fields under **Add new**, either in the **Enrichment Destination** dialog of the datastore that will write here or in the second step of the Add Datastore page, then click **Test connection** and save. The steps are the same for every connector: see [Link an Enrichment Destination](https://userguide.qualytics.io/source-datastore/enrichment-datastore/how-tos/link-enrichment/) or [Link Enrichment on Datastore Creation](https://userguide.qualytics.io/source-datastore/enrichment-datastore/how-tos/link-during-creation/).

*Last updated: November 16, 2026.*
