Pervasive JDBC 2 Driver
JDBC 2 API is supported in Pervasive PSQL. JDBC version 2 is included with JDK version 1.2 and higher. The Pervasive JDBC driver supports this JDBC 2 standard including optional packages.
Table 1
Summary of New Functionality with Pervasive JDBC driver
Feature Element
Notes
Connection Strings
Extra parameter added that allows you to specify which code page to use with the connection.
Improved cursor support
The driver now supports CONCUR_UPDATABLE, TYPE_SCROLL_INSENSITIVE, and TYPE_SCROLL_SENSITIVE
DataSource Interface Support
Register Pervasive PSQL databases in JNDI and your applications can be shielded from Pervasive-specific driver features.
Specifications
The Pervasive JDBC driver is a pure Java type 4 net protocol-based driver. It conforms to the core JDBC 2.x requirements. The driver is similar to the ODBC client driver in functionality and depends on the Pervasive PSQL Engine's ODBC Interface on the server side for the bulk of processing.
Upgrading from the Pervasive JDBC 1 Driver
If you have used the previous Pervasive JDBC 1 Driver, the following topics discuss changes that have occurred with the JDBC 2 Driver.
JDBC API Improvements
•
Scrollable – ability to perform both relative and absolute positioning.
•
Updateable – ability to insert, update, and delete without the need to execute more SQL.
•
Dynamic & Static server-side cursors – ability to choose whether you want to see changes made by you or other users.
•
Batch Updates – ability to queue up many operations and have them execute at once.
•
Character Encoding support – allows you to change encoding per connection.
JDBC Optional Package Support
•
DataSource interface - allows data source objects to be registered in JNDI.
•
Connection Pooling support – complete implementation of the connection pooling interfaces.
Backward Compatibility
Pervasive JDBC version 2 is backward compatible. Applications compiled with previous releases of Pervasive JDBC drivers will work with the new driver without the need to recompile. Applets will need to change the jar file name from pervasiveJDBC.jar to pvjdbc2.jar in the HTML file.
The new driver is accessed through a different package name:
•
com.pervasive.jdbc.v2.Driver will load a JDBC 2 driver
•
pervasive.jdbc.PervasiveDriver will load the JDBC 1 driver
Class Names
With the Pervasive JDBC version 2 driver, class names have changed to comply with Sun recommended standard. All Pervasive classes now are prefaced by com.pervasive.jdbc.v2. In older versions, classes were prefaced by pervasive.jdbc.