Meaningless Drivel is fun!
The moose likes General Computing and the fly likes Database Abstraction Layer : any implementation ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » General Computing
Bookmark "Database Abstraction Layer : any implementation ?" Watch "Database Abstraction Layer : any implementation ?" New topic

Database Abstraction Layer : any implementation ?

Claude Moore
Ranch Hand

Joined: Jun 24, 2005
Posts: 723

Hi there,

I'm wondering if exists any working implementation of a Database Abstraction layer concepts. With Database abstraction layer, I mean
a software which acts as a mediator between your programs and actual DBMS, hiding specific DBMS SQL dialects with one dialect of its own,
and letting you to write stored procs which may transparently access data to different DBMS.

Peter Johnson

Joined: May 14, 2008
Posts: 5852

Java Persistence API (JPA):


There are others. But none handle stored procedures in a generic fashion - those are always database specific (as far as I know)

JBoss In Action
Claude Moore
Ranch Hand

Joined: Jun 24, 2005
Posts: 723

Thank you for your answer, Peter... JPA is a good choice but I had in mind something more similar to a middleware product which would act as a proxy for your queries and stored procedure.

For example, I can run SQL PreparedStatements against that middleware and it in turn will translate on the fly my queries into SQL Server, Db2 or other vendors' SQL specific dialect..

Of course, I have no idea if such software exists...
rohit chavan
Ranch Hand

Joined: Oct 08, 2010
Posts: 132

As mentioned by Peter,
Hibernate already does that.
I agree. Here's the link:
subject: Database Abstraction Layer : any implementation ?
It's not a secret anymore!