MATLAB DATABASE TOOLBOX RELEASE NOTES Guida Utente Pagina 370

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 684
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 369
6 Using Database Toolbox Functions
6-28
results =
Attributes: []
Data: {10000x4 cell}
DatabaseObject: [1x1 database]
RowLimit: 0
SQLQuery: 'select * from BULKTEST'
Message: []
Type: 'Database Cursor Object'
ResultSet: [1x1 oracle.jdbc.driver.OracleResultSetImpl]
Cursor: [1x1 com.mathworks.toolbox.database.sqlExec]
Statement: [1x1 oracle.jdbc.driver.OracleStatementWrapper]
Fetch: [1x1 com.mathworks.toolbox.database.fetchTheData]
columnnames(results)
ans =
'SALARY','PLAYER','SIGNED','TEAM'
10
Close the connection.
close(conn)
Bulk Insert into Microsoft SQL Server 2005
1
Connect to the Microsoft SQL Server. For JDBC driver use, add the JAR file to the
MATLAB Java class path.
javaaddpath 'path\sqljdbc4.jar';
conn = database('databasename','user','password',...
'com.microsoft.sqlserver.jdbc.SQLServerDriver',...
'jdbc:sqlserver://machine:port;
database=databasename');
2
Create a table named BULKTEST.
e = exec(conn,['create table BULKTEST (salary '...
'decimal(10,2), player varchar(25), signed_date '...
'datetime, team varchar(25))']);
close(e)
3
Enter data records. A sample record appears as follows.
A = {100000.00,'KGreen','06/22/2011','Challengers'};
4
Expand A to a 10,000-record data set.
A = A(ones(10000,1),:);
5
Write data to a file for bulk insert.
Vedere la pagina 369
1 2 ... 365 366 367 368 369 370 371 372 373 374 375 ... 683 684

Commenti su questo manuale

Nessun commento

Car alarm manuals

Starting on P page

List of brands for manuals category Car alarm
Brands Top models
Pandora                               RX-151 DXL 3700 RX-155 DXL 2500 Other categories
Pantera                               SLK-85 XS-1500 CLK-500 SLK-500RS Other categories
Pharaon                               V20 x150 V16i SCS-4000 Other categories
Phantom                               Voyager Page FREEROAD I488 Bi-Drive Other categories
Python                               Model 902 702 871XP 436 Series Other categories
Partisan                               i200 RX-5 RX-3 S1 Other categories
PUTHON                               460HP 5206P Other categories
PYLE Audio                               car security system Parking Sensor System PLPSE8WL Other categories
Pioneer                               HIGH DEFINITION PLASMA TELEVISION PRO1130HD Car Stereo Receiver DEH-P5200 Other categories
Prestige-portraits                               APS-20B Other categories
Prime Security                               Prime AMX 38 Other categories
Pro-tec                               Automobile Alarm Other categories
Protec                               Loop Commisioning 6400 Other categories
Pyle                               PWD201 Other categories