JDBC Basics
Most of the Cloudscape tools are JDBC applications. A JDBC application is one that uses the classes in the java.sql package to interact with a DBMS. When you work with JDBC applications, you need to know about the following two JDBC concepts:
Drivers
Before a JDBC application interacts with a database, it must cause the appropriate JDBC driver to be loaded in the Java session. Cloudscape provides three JDBC drivers for use with the Cloudscape database engine. When you use the Cloudscape tools that are JDBC applications, you will need to know which driver to load.
-
COM.cloudscape.core.JDBCDriver
For embedded environments, when Cloudscape runs in the same JVM as the application
-
COM.cloudscape.core.WebLogicDriver
For client/server environments in which Cloudscape runs in the Cloudconnector framework and applications connect via the network
-
COM.cloudscape.core.RmiJdbcDriver
For client/server environments in which Cloudscape runs in the RmiJdbc Server framework and applications connect via the network
ij is a JDBC-neutral application, which means that you can use it to connect to any database that supplies a JDBC driver. For those databases, you would need to load the supplied JDBC driver.
NEW: The COM.cloudscape.core.RmiJdbcDriver driver is new in Version 3.0.
Cloudscape also provides an ODBC driver. Look for information on Cloudscapes Web site.
Database Connection URLs
A JDBC URL provides a way of identifying a database so that the appropriate driver recognizes it and connects to it. In the Cloudscape documents, a JDBC URL is referred to as a database connection URL.
After the driver is loaded, an application must specify the correct database connection URL to connect to a specific database. The Cloudscape database connection URL allows you to accomplish more tasks than simply connecting. For more information about the Cloudscape database connection URLs, see the Cloudscape Developers Guide.
A JDBC URL always starts with jdbc:. After that, the format for the database connection URL depends on the JDBC driver.
For the Cloudscape-provided drivers listed above, here are the formats for the database connection URLs for connecting to an existing database:
NEW: This format of the database connection URL for RmiJcbc is new in Version 3.0. (The old format also works.)
Here are explanations for the italicized items, which stand for something the user fills in:
For complete information about the database connection URL, see the Cloudscape Developers Guide.
|