User`s guide
fastinsert
7-131
[7779] [ 1160] [14.7000] '2014-10-23 10:21...'
[7780] [ 150] [54.5000] '2014-10-23 10:21...'
The last three rows contain the inserted data.
Close the cursor and database connection.
close(curs)
close(conn)
Import Records, Perform Calculations, and Export Data
Connect to the data source dbtoolboxdemo. This data source identifies a Microsoft
Access database. This database contains the tables salesVolume and yearlySales.
conn = database('dbtoolboxdemo','admin','admin');
Alternatively, you can use the native ODBC interface for an ODBC connection. For
details, see database.
Use setdbprefs to set the format for retrieved data to numeric.
setdbprefs('DataReturnFormat','numeric')
Import 10 rows of data from the March column in the salesVolume table.
curs = exec(conn,'select March from salesVolume');
curs = fetch(curs);
Assign the data to the MATLAB workspace variable AA.
AA = curs.Data
AA =
981
1414
890
1800
2600
2800
800
1500
1000