Skip to main content

Preset

You can use Preset, a cloud service for Superset, to query and visualize data.

Supported Authentication Method

Use a personal access token (PAT) obtained from a Sonar project. To obtain one, follow the steps in the section Creating a Token. After you obtain a PAT, it is recommended that you URL-encode it. To encode it locally on your system, you can follow these steps:

  1. In a browser window, right-click an empty area of the page and select Inspect or Inspect Element, depending on your browser.
  2. In the top bar of the inspection pane, click Console.
  3. Type encodeURIComponent("<PAT>"), where <PAT> is the personal access token that you obtained from Dremio Cloud. The URL-encoded PAT appears in red on the next line. You can highlight it and copy it to your clipboard.

Prerequisite

Obtain the ID of the project that you want to connect to in Dremio Cloud. To obtain the ID, follow these steps inside the project:

  1. Click the settings icon on the left navbar.
  2. Click General Information.
  3. Copy the project ID to your system clipboard.

Creating a Connection

  1. Click Settings in the top-right corner, and select Database Connections under Data.

  2. Click the +Database button in the top-right corner.

  3. Select Other from the Supported Databases field of the Connect a Database dialog.

  4. In the Display Name field, specify any name you prefer.

  5. In the Connect a Database dialog, follow these steps:

    1. Select Other from the Supported Databases field.

    2. In the Display Name field, name the new connection.

    3. In the SQLALCHEMY URI field, specify a URI that is in this format. Use an ampersand in front of each additional property that you add:

      SQLAlchemy URI format
      dremio://$token:<PAT>@sql.dremio.cloud:443/<project-ID>;ssl=1[;<option>=<value>[;...]]
      • <PAT>: The URL-encoded personal access token that you obtained from Dremio Cloud. See Supported Authentication Method.
      • <project-ID>: The ID of the project that you want to connect to. See Prerequisite for the steps to obtain the ID.
      • [;<option>=<value>[;...]]: One or more optional encryption properties. Separate each property with a semicolon (;).
      Example SQLAlchemy URI
      dremio://$token:hoYL2mqORpOv1Lq5WNOT-A-REAL-PATq5yeHEYon%2BOT0VHM0JYS%2BCMH7kpL%2BPQ%3D%3D@sql.dremio.cloud:443/1df71752-NOT-A-PROJECT-ID-990e6b194aa4;ssl=1
    4. Test the connection. If the test fails, check the syntax and values in the connection URI.

    5. Click Connect.