Skip to content

Integrate EMQX Tables with MindsDB

MindsDB is an open-source platform that makes it easy to apply machine learning (ML) models to data stored in your existing databases, including EMQX Tables.

EMQX Tables can be accessed from MindsDB using the standard MySQL protocol. Once connected, you can apply advanced ML capabilities such as time-series forecasting on your IoT data with minimal setup.

Configure EMQX Tables in MindsDB

To connect your EMQX Tables instance, use the following SQL statement inside MindsDB to register the external database:

sql
CREATE DATABASE emqx_tables_datasource
WITH ENGINE = 'emqx_tables',
PARAMETERS = {
  "host": "{HOST}",
  "port": 4002,
  "database": "{DB_NAME}",
  "user": "{USER}",
  "password": "~~{PASSWORD}~~",
  "ssl": True
};

Replace {HOST}, {DB_NAME}, {USER}, and {PASSWORD} with your actual EMQX Tables connection details. You can find these credentials on your EMQX Tables Deployment Overview page in the Console.

What's Next

Once connected, you can:

  • Query EMQX Tables data directly from MindsDB
  • Train machine learning models (e.g., time-series forecasting)
  • Use SQL-based interfaces to make real-time predictions

For more advanced usage, refer to the official MindsDB documentation.