This allows a read-only database to be distributed as a single
file instead of as multiple files within a directory and to be compressed.
In fact, a jar or zip file can contain any number of
You cannot store the derby.properties file in a jar or zip file.
To create a jar or zip file containing one or
more
For example, archive the database folder and its contents using the JAR program from the JDK. You can use any zip or jar tool to generate the archive.
This command archives the database directory sales and
its contents into a compressed jar file called dbs.jar.
You can add multiple databases
with jar. For example, this command puts the sales databases and the boiledfood database
(in the subdirectory products) into the archive.
The relative paths of the database in the jar need not match their original relative paths. You can do this by allowing your archive tool to change the path, or by moving the original databases before archiving them.
The archive can be compressed or uncompressed, or individual databases can be uncompressed or compressed if your archive tool allows it. Compressed databases take up a smaller amount of space on disk, depending on the data loaded, but are slower to access.
Once the database is archived into the jar or zip file, it has no relationship to the original database. The original database can continue to be modified if desired.