Main Content

Configure Environment

Driver and data source configuration

Configure a data source depending on the database environment. Decide between using an ODBC and JDBC driver. Then, find the configuration instructions based on your operating system and database. You can configure data sources using the appropriate dialog box in the Database Explorer app. Configure an ODBC data source using the ODBC Data Source Administrator dialog box. Configure a JDBC data source using the JDBC Data Source Configuration dialog box or the command line.

For high-level information about using Database Toolbox™, see Access Relational Database Data in MATLAB. To get started by exploring data visually, use the Database Explorer app.


Database ExplorerConfigure, explore, and import database data


SQLConnectionOptionsDefine JDBC database connection options (Since R2020b)
SQLConnectionOptionsDefine ODBC database connection options (Since R2024a)


expand all

configureODBCDataSourceOpen ODBC Data Source Administrator dialog box
databaseConnectionOptionsCreate database connection options (Since R2020b)
resetReset JDBC or ODBC connection options to defaults (Since R2020b)
rmoptionsRemove JDBC or ODBC connection options (Since R2020b)
setoptionsSet JDBC or ODBC connection options (Since R2020b)
testConnectionTest JDBC or ODBC database connection (Since R2020b)
saveAsDataSourceSave JDBC or ODBC data source (Since R2020b)
deleteDataSourceDelete data source (Since R2020b)
listDataSourcesList all available data sources (Since R2020b)


Database Environment

Windows ODBC

Windows JDBC


Linux ODBC


Linux JDBC

Other Databases

Related Information