MindsDB Information Schema
On start-up, MindsDB consists of one system database (information_schema
), one default project (mindsdb
), and two base tables (models
and models_versions
) that belong to the default project.
You can verify it by running the following SQL commands:
On execution, we get:
And:
On execution, we get:
The information_schema
Database
The information_schema
database contains all the system tables, such as databases
, tables
, columns
, ml_engines
, etc.
You can query for any system information using this query template:
Don’t forget to replace table_name with the table of your interest.
Let’s query for the following:
-
All the available handlers, including data and ML handlers, used to create database connections and AI engines.
Or, alternatively:
-
All the available data handlers used to create database connections.
Or, alternatively:
-
All the available ML handlers used to create AI engines.
Or, alternatively:
-
All the created database connections:
Or, alternatively:
Please note that if you modify the connection arguments in the handler’s code, the changes are visible in this table.
-
All the created AI engines:
Or, alternatively:
The mindsdb
Project
You create models and views within projects. The default project is mindsdb
. But you can create your projects using the CREATE DATABASE
statement, as below:
Here is how to create a model within your project:
And here is how to create a view within your project:
Please replace the integration_name and table_name placeholders with your database name and your table name respectively.
What If Names of a Model and a View are the Same?
Please note that if you use the same name for a model and a view stored in one project, then MindsDB adds _view
to the view name.
Now you can verify that the model and view are within your project:
On execution, we get:
The models
and models_versions
Tables
The mindsdb
project and every project that you create contain these two tables by default:
-
The
models
table stores information about the models within the project, such asname
,status
,accuracy
, and more. -
The
models_versions
table stores information about all present and past versions of each model.
For more information on the models
and models_versions
tables, visit our docs on the PROJECT
entity.
The files
Database
It is another default database that stores all the files uploaded by you to MindsDB Cloud.
Here is how you can upload files to MindsDB.