At a glance
Empire-db is a lightweight yet powerful relational database abstraction layer based on JDBC. It is Open Source and provided under the Apache 2.0 license.
With its unique intuitive and string-free command API you can build virtually any select, insert, update or delete statement independent from the target DBMS. Database entities are managed through dynamic beans which even allow data model changes at runtime. Still it acts passively and gives you full control over connection and transaction handling with zero configuration required.
Empire-db's object model for the schema definition offers unprecedented compile-time safety when building dynamic queries or working with metadata. As a positive side effect your IDE's code completion feature allows browsing of your data model which can dramatically improve productivity.
- No XML schemas or annotations to learn – everything's in Java (Plain Old Java Code).
- Zero configuration footprint - not even one single configuration file!
- DBMS independent data model definition, record handling and command definition, which keeps code portable to all SQL databases.
- Metadata accessible and extensible through standard Java code.
- Type-safe API for dynamic SQL command generation lets you build virtually any SQL statement exactly as you want it; intuitive and completely string-free.
- No need to always work with full database entities. Build queries to provide you with the data exactly as you need it, and obtain the result for example as a list of any type of POJO with matching property setters or constructor.
- Query results or record data may alternatively be obtained as XML even with added metadata.
- Works with dynamic beans and type-safe field access. Special support for data exchange to and from traditional JavaBeans / POJOs is provided.
- Automatic tracking of record state and field modification (aka "dirty checking") to only insert/ update modified fields.
- Support for optimistic locking through timestamp column.
- DDL generation for target DBMS from object definition, either for the entire database or for individual objects such as tables, views, columns and relations.
- Support for data model changes (DDL) at runtime with full dynamic bean support.
- Maximum compile-time safety through the principle of string-free coding. This leads to better code quality and maintainability.
- Metadata support reduces redundancies through all implementation layers.
- Unlimited utilization of the power of SQL helps improving application performance, while retaining full database portability.
- Increased productivity by utilizing the IDE's code completion feature for dynamic query generation and metadata access.
- Easy to learn through intuitive SQL command API.