sun.com/
javase/technologies/database/index.jsp. Since the emergence of JDBC, four different types of
JDBC drivers have been developed. Type 1 is the earliest prototype and the least robust; the Sun JDBC-ODBC
Driver is a Type 1 driver, whereas the I-Net is Type 4. Type 4 drivers are native Java applications and offer the
best connectivity. It??™s best to use a Type 4 driver whenever possible.
The Data Source Name is really an ODBC protocol; except for the JDBC drivers intended to interface with
ODBC, other drivers do not use DSNs. However, the process is much the same??”all you do is supply the
proper parameters identifying the data source. To establish a connection in JSP, follow these steps:
1. Choose Window ??? Databases to display the Databases panel.
2. Click the Add (+) button and select one of the drivers from the drop-down list. The connection dialog
box for the chosen driver is displayed. Figure 19-8 shows the dialog box for the MySQL driver.
FIGURE 19-8
Each of the standard drivers for JSP connections uses placeholders in brackets to indicate
parameters to be completed.
3. If you??™re creating a connection on a testing server, choose the Using Driver On Testing Server
option; otherwise, choose the Using Driver On This Machine option.
Pages:
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157