Before you start
Apache Derby is no longer waiting in the wings -- it has taken center stage as a mature, robust database that can be used almost anywhere. This series of tutorials is for developers or expert users who want to explore the future of data storage. On this journey, expect to combine Derby with other standard tools (both user and developer) to create solutions that solve problems you face every day: ad hoc analysis, document storage, and that newest bugbear, compliance.
This tutorial shows you how to set up a Derby database that you can use as a data store for analysis. The data consumer is immaterial, but you'll use one of the more flexible, powerful tools available: OpenOffice.org Calc. The strengths of this approach are data portability, separation of concerns, and the leveraging of standards and best practices. Most approaches to interfacing with data rely on the use of object-relational mapping tools. However, the goal of this tutorial is actually the opposite: no mapping and direct client access to the underlying data.
You should be reasonably comfortable with standard Java™ tools and have a smattering of Structured Query Language (SQL) experience. The ability to install and configure a Java Virtual Machine (JVM™), Apache Ant or Eclipse, and Derby is required.
To run the examples in this tutorial, you need:
- JVM 1.4.x or later (version 1.5 or later is recommended).
- Approximately 100 to 200MB of free space, depending on your choice of toolset.
- At least 64MB of RAM for your virtual machine (VM).
You should also have the following tools to ensure portability -- both between toolsets and operating systems. I've chosen the Eclipse platform and the Derby plug-ins, but you may want to add the Callisto Data Tools plug-ins as well (although you won't use them during this tutorial). You also need the OpenOffice.org suite of tools, chief among them Base and Calc.
Download and install the following programs:
- Eclipse Workbench, Version 3.x
- Derby plug-ins for Eclipse
- OpenOffice.org Suite, Version 2.x
- Eclipse Callisto Data Tools plug-ins
- Microsoft® Office Excel®