Functions in Database Toolbox

  • By Category | Alphabetical List
  • Database Connection

    Configure Environment

    dexplore Start SQL Database Explorer to import data

    Open and Close Database Connection

    clearwarnings Clear warnings for database connection or resultset
    close Close database connection, DatabaseDatastore, cursor, or resultset object
    database Connect to database
    isconnection Determine if database connections are valid
    isreadonly Determine if database connection is read only
    logintimeout Set or get time allowed to establish database connection
    ping Retrieve status information about database connection
    set Set properties for database, cursor, or drivermanager object
    setdbprefs Set preferences for retrieval format, errors, NULLs, and more
    dexplore Start SQL Database Explorer to import data

    View Information About Database

    database.catalogs Get database catalog names
    database.columns Get database table column names
    database.schemas Get database schema names
    database.tables Get database table names
    get Retrieve object properties
    getdatasources Return names of ODBC and JDBC data sources on system
    isconnection Determine if database connections are valid
    isreadonly Determine if database connection is read only
    ping Retrieve status information about database connection
    bestrowid Unique identifier for row in database table
    columnprivileges List database column privileges
    columns Return database table column names
    crossreference Retrieve information about primary and foreign keys
    dmd Construct database metadata object
    exportedkeys Retrieve information about exported foreign keys
    importedkeys Return information about imported foreign keys
    indexinfo Return indices and statistics for database tables
    primarykeys Get primary key information for database table or schema
    procedurecolumns Get stored procedure parameters and result columns of catalogs
    procedures Get stored procedures for catalogs
    supports Detect whether property is supported by database metadata object
    tableprivileges Return database table privileges
    tables Return database table names
    versioncolumns Automatically update table columns
    dexplore Start SQL Database Explorer to import data

    Data Import into MATLAB

    Run SQL Query

    exec Execute SQL statement and open cursor
    fetch Import data into MATLAB workspace from cursor object or from execution of SQL statement
    fetchmulti Import data from multiple resultsets
    get Retrieve object properties
    resultset Construct resultset object
    rsmd Construct resultset metadata object
    runsqlscript Run SQL script on database
    set Set properties for database, cursor, or drivermanager object
    datastore Create datastore to access collection of data in a database
    dexplore Start SQL Database Explorer to import data
    DatabaseDatastore Access collection of data stored in database

    Display Query Results

    attr Retrieve attributes of columns in fetched data set
    cols Retrieve number of columns in fetched data set
    columnnames Retrieve names of columns in fetched data set
    get Retrieve object properties
    isnullcolumn Determine if last record read in resultset is NULL
    namecolumn Map resultset column name to resultset column index
    querytimeout Get time specified for SQL queries to succeed
    rows Return number of rows in fetched data set
    runstoredprocedure Call stored procedure with input and output parameters
    set Set properties for database, cursor, or drivermanager object
    width Return field size of column in fetched data set
    dexplore Start SQL Database Explorer to import data

    Data Export from MATLAB

    commit Make database changes permanent
    datainsert Export MATLAB data into database table
    fastinsert Add MATLAB data to database table
    insert Add MATLAB data to database tables
    rollback Undo database changes
    update Replace data in database table with MATLAB data
    Was this topic helpful?