Skip to content
PlexBI

Data sources

Link the system your data is kept in, make sure PlexBI can only view it, and describe it so people and the AI understand it.

For: Admins and developers Where: Data → Data sources

What a data source is

A data source tells PlexBI how to reach the database behind one of your business systems (MySQL, PostgreSQL and others). Not sure where yours is? Your IT person or software supplier will know. Reports, alerts and forms read from it. PlexBI uses the login you give it and never copies the data out.

Add a data source

  1. Go to Data sources and choose New data source.
  2. Under Where is your data kept?, pick the kind of database. Keep your data in Excel? Choose Upload a spreadsheet instead.
  3. Fill in Name (what people will see, for example Northwind orders), Host, Port, Database, Schema (optional), Username and Password. The password is stored encrypted.
  4. Leave Encrypted connection ticked, so your data and the login travel encrypted. Untick it only if the database does not accept encrypted connections.
  5. Choose Test connection. PlexBI connects and checks whether the login can change data.
  6. If it says Read-only, continue. If it says Login can change data, see the next section first.
  7. Answer Do you want to use the AI with this database? You can change this any time.
  8. Under What is this database? write a sentence or two, for example Northwind’s order system. One row per order line in sales; amounts in US dollars, without tax.
The first step of a new data source: choosing where the data is kept
The first step of a new data source: choosing where the data is kept

Make sure the login can only read

Dashboards should never be able to change your data. If the test says Login can change data, choose Create a read-only login. PlexBI writes the SQL that creates a login that can only read; whoever manages the database runs it once. Then choose Use this login in the form and save.

You can check again at any time from the connection’s menu: Check access.

Keep the connection encrypted

A card marked Not encrypted sends your data and the login across the internet in a form anyone in between could read. Open the card’s menu, choose Edit connection, tick Encrypted connection and save. If the test then fails, ask whoever manages the database to turn on TLS, or connect through an SSH server (below), whose tunnel is encrypted.

A database in a private network (SSH)

Most company databases are not open to the internet. If your IT team has an SSH server (a “jump host”) inside that network, PlexBI can sign in to it and reach the database from there, so the database stays closed.

  1. Tick Connect through an SSH server.
  2. Fill in SSH server, SSH port (usually 22) and SSH username.
  3. Under Sign in with, choose Private key (paste it, or Or choose the key file, plus its passphrase if it has one) or Password. A key is safer.
  4. For Host above, use the database’s address as the SSH server sees it: often 127.0.0.1 when the database runs on the SSH server itself.
  5. Choose Test connection. The first time, PlexBI shows the SSH server’s fingerprint under Is this your SSH server? Check it with whoever manages the server, then choose It matches: trust it and test.

PlexBI remembers that fingerprint and refuses to connect if it ever changes, so another server cannot pose as yours. The key or password is stored encrypted and never shown again. Encrypted connection is unticked for you here: the SSH tunnel is encrypted already. On PlexBI’s shared servers a Host in a private network (such as 10.0.0.5 or 192.168.1.20) is refused, so use SSH for those.

Describe the data (the guide)

Each connection has a guide that explains the database in plain words. People read it to understand the data, and the AI reads it instead of your data. Open it from the connection card (Describe the data).

  1. About this database: what it holds and its units.
  2. Business rules and terms: for example Revenue is sales.revenue, excluding tax. An active customer ordered in the last 90 days.
  3. Tables and columns: describe the ones that matter. Names that explain themselves, such as created_at, need nothing.
  4. How tables join: which column points to which, such as sales.customer_id to customers.id.
  5. Financial year: only if this database belongs to a business whose year differs from the company’s.
The guide for Northwind orders, with About this database, business rules, tables and joins
The guide for Northwind orders, with About this database, business rules, tables and joins

The connection card

Each card shows what is set up and what is left, such as Finish setup, Check access or Describe the data. The More actions menu has Edit connection, Check access, What the AI may see (tables and columns the AI is allowed to know about), Slow queries and Build with AI.

The Northwind orders connection card, marked Read-only, AI on and Guide 100%
The Northwind orders connection card, marked Read-only, AI on and Guide 100%

Slow queries

Under Slow queries PlexBI shows how long each widget takes, which ones are slow, and what would help: an index on the database, or caching the dashboard for a few minutes. It gives the exact SQL for an index, to pass to whoever manages the database.

Example

Northwind adds Northwind orders (MySQL). The test says Login can change data, so Priya chooses Create a read-only login, sends the script to their IT partner, and switches to the new login. In the guide she writes that revenue is in US dollars without tax, and joins sales.customer_id to customers.id.