2D or 3D graphical routines, 4
data. See also entity beans
Enterprise JavaBeans, 41–42
entry, auto-generated keys, 158–159
modifying, 18
structure, multitier applications, 324–325
Data Definition Language (DDL)
checking, 421
defined, 17
tables, creating, 268–269
data logic, 8
Data Manipulation Language (DML), 427
data source
Java Database Connectivity (JDBC), 28
multiple. See distributed transactions
name, setting, 532
Open Database Connectivity (ODBC), 22
data stores. See resource tier
data streams, 72
data truncation
defined, 72
unexpected (DataTruncation exception), 381–382
data types, mapping
ARRAY, 345–348
BIGINT, 181–182
BINARY, 182
BIT, 181
Blob or BLOB, 221
Boolean, 182
byte, 182
char or CHAR, 181
clob or CLOB, 179
DATALINK, 500
date or DATE, 430
DECIMAL, 181
DISTINCT, 179
double or DOUBLE, 181
entity beans, 200
FLOAT or float, 180–181
int or INTEGER, 180–181
JAVA_OBJECT, 93
LONGVARBINARY, 182
LONGVARCHAR, 458
NUMERIC, 181
REAL, 179–181
Ref or REF, 179
short, 113
SMALLINT, 180–181
String, 182
Struct or STRUCT, 511–512
time or TIME, 182
timestamp or TIMESTAMP, 182
TINYINT, 180–181
Unicode character stream, 468
VARBINARY, 182
VARCHAR, 181
database
applets, 48
client/server architecture, 14–15
connection method, 46
driver, 34
engine specifications and limitations, 275
errors (SQLException), 489–491
information, 162–165
integrating, 23–36
integrating changes made in RowSet, 36
limitations, 275
objects, 168–174
Open Database Connectivity (ODBC) standard, 20–22
relational, explained, 13–14
sample URLs, 58
Structured Query Language (SQL) standard, 16–20
tier location, 40
version numbers, getting, 396–397
warnings (SQLWarning), 501–502
database connections
closing, 62–63
creating, 60–62
Java Database Connectivity (JDBC) driver, specifying, 58–60
multiple, 10
naming scheme, 56–58
parameters, necessary, 55–56
properties, adjusting, 63–64
steps, 64–66
database cursors, 15
database engine, 162–165
database explorer application
catalogs, browsing, 275–278
database engine specifications and limitations, 275
described, 271–272
interactive Structured Query Language (SQL) tool, 278–280
logging in, 272–274
navigation graphical control, 274
source code, 280–323
database management system (DBMS)
applications sending Structured Query Language (SQL) statements. See JDBC)
defined, 13
examples listed, 32–33
interfaces, 53–55
database transactions
account balance and other controls, 255–256
ATM panel, 256–257
clock, updating (TimeT.java), 267
HyperText Markup Language (HTML) file, 257
interface, 35
isolation mode, 539–540
multiple, 424
NetBank.java class, 262–266
preserving ResultSets across, 133
processing monitors, 12
support, checking, 428
tables, creating (Data Definition Language (DDL)), 268–269
usefulness, 253
welcome screen, 254
DatabaseMetaData
features supported, 165–166
field, 383–389
information, 373
limitations, 166–168
objects, 168–174
DATALINK
callable statement, 366–367
data type conversion, 500
DataSource objects, 522–524
DataTruncation exception, 381–382
date and time functions
listing, 411–412
Structured Query Language (SQL) escape syntax, 122–123
date or DATE
callable statements, 361–362
column, getting as, 459–460
column, updating, 477
parameter, setting, 532
prepared statements, 444
reading, 493
String, converting to, 89
type conversions, 430
writing, 497
DB2
sample driver, 59
sample URL, 58
DBMS. See database management system (DBMS)
DCE. See Distributed Computing Environment (DCE) naming service
DDL. See Data Definition Language (DDL)
deadlocks, preventing, 126
DECIMAL, 181
deleting
with cursors, 137–138
detecting, 543
positioned, 426
rows, 453
savepoint, 378
tables, 17
deployment descriptors, 192
development, 37
direct invocation, Structured Query Language (SQL), 16
dirty reads, 539–540
DISTINCT data, 179
Distributed Computing Environment (DCE) naming service, 57
distributed services, 4
distributed transactions
advantages, 10
JDBC 3.0 Extension (J2EE) interface (XAConnection), 550
transaction management, 130–131
DML. See Data Manipulation Language (DML)
double or DOUBLE
callable statements, 362
column, updating, 477
column value, getting, 460
parameter, setting, 533
prepared statements, 444
reading, 493
type conversions, 181
writing, 497
driver
choosing, 59
integration tier, 40
Java Database Connectivity (JDBC), 431–432
Open Database Connectivity (ODBC), 51
required to use book, 11
sample, 59–60
specifying, 58–60
time outs, setting, 73–74
version number, getting, 398
DriverManager
choosing driver, 59
defined, 46
methods, 432–436
Open Database Connectivity (ODBC), 21
queries and updates, refining, 109–112
user application and, 33
DriverPropertyInfo class, 436–437
durability, data, 125
dynamic bindings, 5
dynamic Structured Query Language (SQL), 34
dynamically typed data
inserting or updating, 180–183
retrieving, 178–180