Skip to main content

Requirements

To follow the steps in this guide, you’ll need:
  • Organization Admin permissions in Omni
  • Permissions in MySQL that allow you to create database users

Setup

1

Create a database user for Omni

In your MySQL database, run the following command to create a database user for Omni:
Create Omni user
Next, run the following command to grant the Omni user access to the database:
Grant SELECT permissions to Omni user
2

Set up a table upload schema

This step is optional. However, we recommend completing it as part of the initial set up or you won’t be able to use uploaded files like CSVs in joins.
In this step, you’ll create a dedicated schema to use for table uploads. This schema can’t be used for other modeled tables.
  1. Create the schema in MySQL.
  2. Run the following commands to grant the Omni user the required privileges:
    Grant Omni user permissions to upload schema
3

Allowlist Omni's IP addresses

If access to the MySQL database is limited by IP address, you’ll need to add Omni’s IPs to the allowlist before you create the database connection.Omni’s IP addresses can be found on an individual connection’s page, accessed by navigating to Settings > Connections and clicking a connection.
4

Create the connection in Omni

  1. In Omni, click Settings > Connections.
  2. Click the MySQL option.
  3. On the connection setup page, fill in the connection details:
    required
    A user-friendly name for the connection, which will be used throughout Omni.
    required
    The address of the database server.
    default:"3306"
    required
    The port number for the database connection.
    required
    The database to connect to.
    required
    The username for database authentication.
    required
    The password for database authentication.
    required
    The timezone used by the database.
    required
    The timezone to use for Omni queries. If a timezone is specified, data will be converted from the Database Timezone to the selected timezone.
    When enabled, users can override the connection timezone with their own when querying.
    default:"900"
    Maximum time in seconds before a query times out.
    default:"enabled"
    When enabled, Omni will automatically infer relationships between tables based on column name matching during schema refreshes. Defaults to enabled.
    required
    Select the minimum level of access users should have to models in the connection.
  4. When finished, click Create connection.

What’s next?

Now that your database is set up, you can: