Java DB

Apache Derby

Derby Tools and Utilities Guide

Derby Getting Started
Derby Reference Manual
Derby Developer's Guide
Derby Performance Tuning
Derby Server and Admin Guide
Derby Tools and Utilities
Derby Tools and Utilities
-Copyright
-License
-About this guide
-What are the Derby tools and utilities?
-Using ij
-ij properties reference
-ij commands and errors reference
-ij commands
-Absolute command
-After Last command
-Async command
-Autocommit command
-Before First command
-Close command
-Commit command
-Connect command
-Describe command
-Disconnect command
-Driver command
-Elapsedtime command
-Execute command
-Exit command
-First command
-Get Cursor command
-Get Scroll Insensitive Cursor command
-Help command
-Last command
-LocalizedDisplay command
-MaximumDisplayWidth command
-Next command
-Prepare command
-Previous command
-Protocol command
-Readonly command
-Relative command
-Remove command
-Rollback command
-Run command
-Set Connection command
-Show command
-Wait For command
-Syntax for comments in ij commands
-Syntax for identifiers in ij commands
-Syntax for strings in ij commands
-ij errors
-Using the bulk import and export procedures
-Storing jar files in a database
-sysinfo
-dblook
-SignatureChecker
-Trademarks

 

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 Derby 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 Derby database connection URL allows you to accomplish tasks other than simply connecting. For more information about the Derby database connection URLs, see the Derby Developer's Guide.

A JDBC URL always starts with jdbc:. After that, the format for the database connection URL depends on the JDBC driver.

Here is the format for the database connection URL for connecting to an existing Derby database using the embedded driver:
  • jdbc:derby:databaseName;URLAttributes
The format for the database connection URL for connecting to an existing Derby database using the Network Client is:
  • jdbc:derby://host:port/databaseName;URLAttributes
The italicized items stand for something the user fills in:
  • databaseName

    The name of the database you want to connect to. This might also include the file system path to the database.

  • URLAttributes

    One or more of the supported attributes of the database connection URL, such as upgrade=true, create=true or territory=ll_CC. For more information, see "Setting attributes for the database connection URL" in the Derby Reference Manual.

  • host

    The name of the machine where the server is running. It can be the name of the machine or the address.

  • port

    The port number used by the server framework

About Protocols

Officially, the portion of the database connection URL called the protocol is jdbc:, just as http:// is a protocol in Web URLs. However, the second portion of the database connection URL (everything between jdbc: and databaseName), which is called the subprotocol, is informally considered part of the protocol. Later in this book you might see references to protocol. Consider protocol to be everything that comes before databaseName.

For complete information about the database connection URL, see the Derby Developer's Guide.

 

javadb@jdbcurl.com