I was toying around with some free and non-free databases, but found
nothing that offers what I need. Therefor I wrote a database myself in
100% Java, by implementing the JDBC interfaces (java.sql.*): just copy
them to a class and start writing.
I'm almost there for what I need of it, but if there is sufficient
interest I might do an extra effort. Just tell me what you like or
need, and I'll have a look at it.
However I do not share the sources yet, because
1. they are too much unfinished/unpolished
2. I have no experience with managing a cooperative programming
project or whatever you linux builders call it
What is in my package now or soon:
- zero installation: 100% java, just jar the classes (or do you prefer
explaining to an end-user how to install Access and an ODBC driver for
it, and then enter the right names at the right places for your
JDBCODBC bridge?)
- needs no expensive DB server at the other end of a Web connection.
In fact, it was created for single user applications (or applets?)
- I yet have to check wether multi-user access would pose a problem.
But my clients are dentists, and few of them work at the same patient
at the same moment (though once I had my dentist call in his brother
dentist-in-spe to help pulling, but none of them bothered about the
computer at that moment)
- supports following SQL subset
SELECT
[* | table1.* | table2.column]...
FROM table1...
WHERE [table1].column1
[<,<=,>,>=,<>,=,LIKE]
[ [table2].field2 | string literal | numeric literal] ...
ORDER BY [table1.]column1 ...
DELETE FROM table1
WHERE (see SELECT)
UPDATE table1
SET column1 = [string literal | numeric literal | bit literal] ,...
WHERE (see SELECT)
INSERT INTO table1
[(column1, ...)]
VALUES ([string literal | numeric literal | bit literal] ,...)
CREATE TABLE table1
(column1 [CHAR(n) | VARCHAR | LONGVARCHAR
| BINARY(n) | VARBINARY | LONGVARBINARY
| BIT | TINYINT | SHORTINT | INTEGER | BIGINT
| DECIMAL(p,s) | NUMERIC | DATE | TIME | TIMESTAMP] , ...)
DROP TABLE table1
- I just managed to get a copy of (a preview of) SQL92 specs, and
formatted it into HTML for easier reading/hyperlinking, so expect more
SQL statements later (these SQL92 specs seem hard to get. is there any
interest in them as well?)
- has a javax.swing.table.TableModel implementing ResultSet
- has a database-based resourcebundle
- tables reside in human-readable/editable ASCII text files
(comma-separated values) or HTML files (using a much faster
StringTokenizer than the standard java.util.~ one)
- pluggable data parser/formatter for using your own file formats
- data tables from even more source types can be plugged into the
resultset as java arrays or vectors
- JDBC-based (though not formally JDBC compliant, for I don't do full
SQL entry level yet)
- some JDBC 2 support already, though some of it is commented out
cause I cannot compile it all while I need to be on JDK116
- lightweight: present total class size 146kB, of which some may be
left out depending on the needs of the application, like e.g.
PreparedStatement, DatabaseMetaData, DBResourceBundle, ...
I'm also considering separate classes for query and for update
statements, in case you need a read-only database (e.g. the HTML file
your applet runs in)
- arithemtic expressions are going to be in it too
- some date functions are already in, others will follow when I need
them
- speed as fast as java
Why did I build it:
- I needed zero install as a starter. When users like my applications,
they might pay me to install more performant or reknowned databases or
JDBC or JDBC/ODBC drivers for them.
- I want the database to be human readable, so information stored
through my application can be communicated to others that don't have
the information. No need for exports.
- I needed a modifyable ResourceBundle. The standard implementations
PropertyResourceBundle and ListResourceBundle are too weak at this:
Did you ever notice that PropertyResourceBundle uses a private
Properties field as storage? Well, Properties has a setProperty() and
a save() method, but PropertyResourceBundle gives you no access to
it). And it supports String resources only. ListResourceBundle stores
it's resources in a java class file, so again at runtime you cannot
update them. It sucks.
- Above all, it's fun
^ _/_/_/_/ _/_/ _/_/_/_/ _/ _/ v
^ _/ _/ _/_/ _/ _/ _/ _/ v
^ _/ _/ _/_/ _/_/_/_/ _/_/_/ v
^ _/ _/ _/_/ _/ _/ _/ _/ v
^ _/_/_/_/ _/_/ _/ _/ _/ _/ v
<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
Dirk de Pirk