apache > db
Apache DB Project
Font size:      

Apache Derby Release


Use the links below to download a distribution of Apache Derby. You should always verify the integrity of distribution files downloaded from a mirror.

There are four different distributions:

  • bin distribution - contains the documentation, javadoc, and jar files for Derby.
  • lib distribution - contains only the jar files for Derby.
  • lib-debug distribution - contains jar files for Derby with source line numbers.
  • src distribution - contains the Derby source tree at the point which the binaries were built.

db-derby- [PGP] [MD5]
db-derby- [PGP] [MD5]

db-derby- [PGP] [MD5]
db-derby- [PGP] [ MD5]

db-derby- [PGP] [MD5]
db-derby- [PGP] [MD5]

db-derby- [PGP] [MD5]
db-derby- [PGP] [MD5] (Note that, due to long filenames, you will need gnu tar to unravel this tarball.)

There are two separate Eclipse plugins for Derby:

  • derby_core_plugin - provides the Derby jar files to other plugins in Eclipse.
  • derby_ui_doc_plugin - provides an Apache Derby Nature in Eclipse for easy database application development.

derby_core_plugin_10.8.2.zip [PGP] [MD5]
derby_ui_doc_plugin_1.1.3.zip [PGP] [MD5]

Please note: both plugins must be installed for full functionality. For information on installing and using the Derby plugins for Eclipse, please see the Using the 10 Core and 1.1 UI Derby plug-ins p age.

Release Notes for Apache Derby

These notes describe the difference between Apache Derby release and the preceding release


The most up to date information about Derby releases can be found on the Derby download page.

Apache Derby is a pure Java relational database engine using standard SQL and JDBC as its APIs. More information about Derby can be found on the Apache web site. Derby functionality includes:

  • Embedded engine with JDBC drivers
  • Network Server
  • Network client JDBC drivers
  • Command line tools: ij (SQL scripting), dblook (schema dump) and sysinfo (system info)

Java and JDBC versions supported:

  • Java SE 1.4 and higher with JDBC 2.1, 3.0, 4.0 and 4.1
  • Java ME CDC/Foundation Profile 1.1 with JSR-169 JDBC Optional Package for CDC/Foundation Profile.

New Features

This is a bug fix release. No new features were added.

Bug Fixes

The following issues are addressed by Derby release These issues are not addressed in the preceding release.

Issue IdDescription
DERBY-5452Possible NPE in NsTest.printException()
DERBY-5448In the 10.8 branch, back out the concurrency improvements introduced by using SequenceUpdaters to allocate identity values.
DERBY-5447Deadlock in AutomaticIndexStatisticsTest.testShutdownWhileScanningThenDelete (BasePage.releaseExclusive and Observable.deleteObserver (BaseContainerHandle))
DERBY-5445Enhance existing concurrency test to stress sequence generators to also stress identity columns
DERBY-5444SpawnedProcess.complete may fail to destroy the process when a timeout is specified
DERBY-5438Empty MAPS table in toursdb
DERBY-5426Improve the error raised by too much contention on a sequence/identity.
DERBY-5421NullPointerException during system.nstest.utils.Dbutil.update_one_row
DERBY-5419Make Derby run on Oracle Java ME Embedded Client
DERBY-5418Network server session's close method neglects to close down any open trace file
DERBY-5414SysDiagVTIMappingTest.test_5391() failed: java.text.ParseException: Unparseable date: "Thu Sep 15 14:00:16 CEST 2011"
DERBY-5413NetworkServerControl#main can exit with status 1 without printing an error message to console
DERBY-5412MemoryLeakFixesTest.testRepeatedDatabaseCreationWithAutoStats() fails on phoneME: java.lang.InternalError: Number of class names exceeds vm limit.
DERBY-5409GrantRevokeDDLTest fails under Java 7
DERBY-5408parameters for message 2200H - sequence generator does not cycle - is out of sync in non-English messages
DERBY-5404Document DBO restriction for four diagnostic VTIs
DERBY-5402Assignment instead of comparison in Driver20.getPropertyInfo
DERBY-5398NullPointerException in storemore/bug3498.sql
DERBY-5396DRDAStatement and DRDAConnThread swallow IOExceptions
DERBY-5395By default, only the DBO should be allowed to run several of the diagnostic VTIs.
DERBY-5394Reduce chance of OOME with XAMemTest.testDerby4137_TransactionTimeoutSpecifiedNotExceeded in low memory suite
DERBY-5393Remove old in-memory database purge mechanism
DERBY-5391The syscs_diag.error_log_reader() and syscs_diag.statement_duration() vtis do not work on derby error logs created since 10.7.1
DERBY-5390NPE in BasicDatabase.stop in replication slave mode (dd.clearSequenceCaches)
DERBY-5389SequenceGeneratorTest failures with weme 6.2 sane build ASSERT FAILED Identity being changed on a live cacheable
DERBY-5385Improve documentation for OFFSET/FETCH NEXT
DERBY-5384Reference Guide talks about a DriverManager method which does not exist.
DERBY-5376Documentation should state authentication/authorization requirements more strongly
DERBY-5372Need to document that the != and <> operators are pushed into Restricted table functions (once the work on DERBY-5369 wraps up)
DERBY-5367Stale data retrieved when using new collation=TERRITORY_BASED:PRIMARY feature
DERBY-5362HTML frameset files lack closing newline character
DERBY-5361Document use of URLs with SQLJ.INSTALL_JAR
DERBY-5354Remove unnecessary dita.regex build target
DERBY-5352Derby table functions stored in a jar file inside the database which implement VTICosting or RestrictedVTI fail with ClassNotFoundException
DERBY-5350Devguide needs update for definer's rights
DERBY-5339Sample domain names should follow RFC 2606 conventions
DERBY-5336Repeated database creation causes OutOfMemoryError
DERBY-5334Incorrect permission arguments given for SYSCS_UTIL.SYSCS_SET_USER_ACCESS
DERBY-5333Intermittent assert failure in testInterruptShutdown: thread's interrupted flag lost after shutdown
DERBY-5331Incorrect use of CharsetEncoder in DDMWriter
DERBY-5329Document who is allowed to run which system procedures/functions.
DERBY-5325Checkpoint fails with ClosedChannelException in InterruptResilienceTest
DERBY-5318Use assertDirectoryDeleted in ReplicationRun and remove dead code
DERBY-5314Enable i18n tests in non-English locales
DERBY-5312InterruptResilienceTest failed with ERROR 40XD1: Container was opened in read-only mode.
DERBY-5307Document the behavior of the derby.language.sequence.preallocator property.
DERBY-5304test_derby_4779 (lang.GeneratedColumnsTest) fails with ibm 1.4.2; ERROR 42X50; No method was found that matched the method call java.lang.Integer.signum(int)
DERBY-5299Document what you should expect to see if you enable authentication/authorization on a database which was created without those safeguards.
DERBY-5292SQLAuthorisation and views
DERBY-5291test failure: NullPointerException with J2ME (weme 6.2) in testDerby4137_TransactionTimeoutSpecifiedNotExceeded(org.apache.derbyTesting.functionTests.tests.memory.XAMemTest)
DERBY-5289Unable to boot database - fails during soft/hard upgrade process for a new version number while trying to drop jdbc metadata
DERBY-5284A derby crash at exactly right time during a btree split can cause a corrupt db which can not be booted.
DERBY-5280Large batch of DDL in a database procedure dies on a transaction severity error.
DERBY-5278AssertionFailedError in IndexSplitDeadlockTest.testBTreeForwardScan_fetchRows_resumeAfterWait_unique_split()
DERBY-5276Reference manual has wrong length for BIGINT columns in system tables
DERBY-5274getColumns() doesn't work with auto generated identity columns that start with large numbers
DERBY-5271Client may hang if the server crashes due to a java.lang.Error
DERBY-5264OOM issue using XA with timeouts with Java 1.4
DERBY-5262Running JUnit tests with Java 1.4.2 fails if the package private tests are on the classpath
DERBY-5258btree post commit releases latch before committing/aborting purges, possibly allowing other operation on page
DERBY-5255Fix more difficult table problems
DERBY-5254The keywords introduced by the CREATE SEQUENCE work are treated as reserved rather than unreserved.
DERBY-5253Engine code references org.apache.derby.shared.common.sanity.SanityManager
DERBY-5252make GrantRevokeTest pass in non-English locale
DERBY-5251make ErrorCodeTest pass in non-English locale
DERBY-5249A table created with with constraints cannot be dropped with 10.5 due to NullPointerException with insane build or ASSERT FAILED Failed to find sharable conglomerate descriptor for index conglomerate with sane build
DERBY-5247Warnings regarding XPath displayed when generating JavaDoc
DERBY-5243assert failure in test testRAFReadWriteMultipleThreads: interrupted flag cleared
DERBY-5239Remove usages of DriverManager to obtain an Embedded Connection in Derby Server
DERBY-5238VARCHAR size typos in some documentation topics
DERBY-5236Client driver silently truncates strings that exceed 32KB
DERBY-5233Interrupt of create table or index (i.e. a container) will throw XSDF1 under NIO - connection survives
DERBY-5226SQLJ system procedures should be documented in Reference Manual
DERBY-5223Thread's interrupted flag not always preserved after Derby returns from JDBC API call
DERBY-5222Compatibility tests fail to delete database directory
DERBY-5217make ImportExportIJTest pass in non-English locale
DERBY-5215Localize messages introduced or changed in 10.7 and 10.8
DERBY-5212Reference Manual: language on authentication/authorization needs changes for several URL attribute topics
DERBY-5211Make SysinfoCPCheckTest pass in non-English locale
DERBY-5205Documentation: toc.html files need lang attribute
DERBY-5204Misplaced p tags in release notes
DERBY-5203Documentation of drop=true attribute contains error
DERBY-5198XPLAIN table documentation needs some cleanup
DERBY-5191Documentation needed for connection URL attribute retrieveMessageText
DERBY-5184Tables in documentation need introductions and formatting fixes
DERBY-5158Incomprehensible error message on client if attempting rollback after database has been shut down.
DERBY-5120Row from SYSDEPENDS gets deleted when a table has update triggers defined on it and an upate is made to the table
DERBY-5108Intermittent failure in AutomaticIndexStatisticsTest.testShutdownWhileScanningThenDelete on Windows
DERBY-5098embedded/in-memory: SQLNonTransientConnectionException: No current connection due to invalid page format
DERBY-5097testMTSelect(org.apache.derbyTesting.functionTests.tests.store.AutomaticIndex StatisticsMultiTest)junit.framework.AssertionFailedError: failed to get statisti cs for table MTSEL (#expected=2, timeout=0) on AIX IBM JDK 1.5
DERBY-5084convert ijConnName.sql to a ScriptTest junit test
DERBY-5044ALTER TABLE DROP COLUMN will not detect triggers defined on other tables with their trigger action using the column being dropped
DERBY-5014Tests should restore the timeout values to default after they are done running.
DERBY-4984ALTER TABLE DROP COLUMN may leave triggers invalid even if they are not using the column getting dropped.
DERBY-4779NPE while inserting into a table which has a generated column and an insert trigger
DERBY-4670ThreadDump class included in insane jars
DERBY-4669ClassLoaderBootTest fails if derbyclient.jar comes before derby.jar on the classpath
DERBY-4647BaseTestCase.execJavaCmd() does not work with weme 6.2
DERBY-4637The Developer's Guide implies that, for in-memory database names, Derby does not resolve relative and absolute paths to the same in-memory database
DERBY-4617Sysinfo.testSysinfoLocale failed with IB47 M 1.6 on Windows 7 64bit
DERBY-4443Wrap rollback in exception handlers in try-catch
DERBY-4408missing DOCTYPE and META tags in toc.html and index.html pages
DERBY-4275Query executions fail when compressing a table using SYSCS_UTIL.SYSCS_COMPRESS_TABLE
DERBY-4260Make derbynet/NetworkServerControlClientCommandTest run regardless of the locale
DERBY-4200client side OutOfMemoryError running derbnetclientmats:jdbcapi/derbyStress
DERBY-4137OOM issue using XA with timeouts
DERBY-3870Concurrent Inserts of rows with XML data results in an exception
DERBY-3337convert jdbcapi/derbyStress.java to JUnit
DERBY-2625SEVERE error involving column-width property
DERBY-2623SEVERE error involving column-number property
DERBY-2254Assert during log file switch: log file position exceeded max log file size
DERBY-1903Convert largedata/LobLimits.java to junit
DERBY-1780Document all supplied system procedures in the Server and Administration Guide (e.g. class loading utils and import/export)
DERBY-1046JVMInfo is duplicated in derbyclient.jar
DERBY-484Documentation for derby.database.classpath in developers guide is misleading
DERBY-159When Derby runs in Network Server mode, client does not receive warnings generated by Derby - should get documented


Compared with the previous release (, Derby release introduces the following new features and incompatibilities. These merit your special attention.

Note for DERBY-5395

Summary of Change

Now, only the database owner may view several diagnostic VTIs: syscs_diag.statement_cache, syscs_diag.transaction_table, syscs_diag.error_log_reader( ), and syscs_diag.statement_duration().

Symptoms Seen by Applications Affected by Change

Previously in a database with SQL authorization enabled, any user could select from those diagnostic VTIs. Now only the database owner can.

Incompatibilities with Previous Release

Application designers should ensure that only the database owner selects from these VTIs. For most applications this should not be a problem since the VTIs are intended to be used in production only as technical support tools.

Rationale for Change

These VTIs reveal sensitive information which only authorized persons should see.

Application Changes Required

Table functions with definer's rights can be used to grant other users access to the information in these VTIs. For instance, the following technique can be used to let ordinary users view the non-sensitive data in syscs_diag.statement_cache:

First, create a static Java method which selects only the non-sensitive columns:

import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.SQLException;

public class SafeCacheViewer
    public  static  ResultSet   safeCacheViewer()   throws SQLException
        return DriverManager.getConnection( "jdbc:default:connection" ).prepareStatement
            ( "select id, schemaName, valid, compiled_at from syscs_diag.statement_cache" ).executeQuery();

Then the database owner should register the method as a table function enjoying definer's rights, and grant EXECUTE privilege on it to PUBLIC:

create function safeCacheViewer()
returns table
    id char( 36 ),
    schemaName varchar( 128 ),
    valid boolean,
    compiled_at timestamp
language java parameter style derby_jdbc_result_set reads sql data
external security definer
external name 'SafeCacheViewer.safeCacheViewer';

grant execute on function safeCacheViewer to public;

Finally, other users can select data from the table function as follows (here test_dbo is the schema of the database owner):

select * from table( test_dbo.safeCacheViewer() ) s;

Build Environment

Derby release was built using the following environment:

  • Branch - Source code came from the 10.8 branch.
  • Machine - Windows XP Professional Version 2002 Service Pack 3
  • Ant - Apache Ant version 1.7.0 compiled on December 13 2006.
  • JDK 1.4 - Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2) Classic VM (build 1.4.2, J2RE 1.4.2 IBM Windows 32 build cn142ifx-20110211 (SR13 FP8+PM31983)).
  • Java 6 - Java(TM) SE Runtime Environment (build pwi3260sr9fp1-2011-0208_03(SR9 FP1) IBM J9 VM (build 2.4, JRE 1.6.0 IBM J9 2.4 Windows XP x86-32 jvmwi3260sr9-20110203_74623).
  • Compiler - The 1.6.0-b105 javac was used to compile all classes.
  • JSR 169 - Java ME support was built using libraries from IBM's j9 jvm from WEME 6.2.

Verifying Releases

It is essential that you verify the integrity of the downloaded files using the PGP and MD5 signatures. MD5 verification ensures the file was not corrupted during the download process. PGP verification ensures that the file came from a certain person.

The PGP signatures can be verified using PGP or GPG. First download the Apache Derby KEYS as well as the asc signature file for the particular distribution. It is important that you get these files from the ultimate trusted source - the main ASF distribution site, rather than from a mirror. Then verify the signatures using ...

% pgpk -a KEYS
% pgpv db-derby-X.Y.tar.gz.asc


% pgp -ka KEYS
% pgp db-derby-X.Y.tar.gz.asc


% gpg --import KEYS
% gpg --verify db-derby-X.Y.tar.gz.asc

To verify the MD5 signature on the files, you need to use a program called md5 or md5sum, which is included in many unix distributions. It is also available as part of GNU Textutils. Windows users can get binary md5 programs from here, here, or here.

We strongly recommend that you verify your downloads with both PGP and MD5.