Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

DB abstraction summary? Making sense of the offerings...

 
John Wells
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Guys,
There's an overwhelming amount of database abstraction/access libraries/frameworks/etc. available for Java.
I'm returning to heavy Java db programming after years of absence (aside from some small code every now and then...), and don't really know where to begin. We used to write straight JDBC queries, but it seems the world has moved on, and I'd like to take advantage of the mass of innovation that has been done.
Is there a central resource out there that summarizes the available options (JDO, DAO, Hibernate, etc. etc.) and offers the benefits/drawbacks as well as when you might want to use each?
I appreciate any pointers or links or advice you can provide.
Thanks for your help!
 
Hanna Habashy
Ranch Hand
Posts: 532
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi John:
I don't have much experience useing framworks for JDBC. I am still taking my baby steps. I found this book is very helpfull for me, and I thought you might want to take a look at it.
Core J2EE patterns, ISBN 0-13-142246-4
 
Marshall B Thompson
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My take is use jdbc to call stored procedures in your database. O/R layers get in the way in my opinion. Abstract something that a developer should already know (PL/SQL, T-SQL,...etc) into something new that they should learn. Makes debugging harder too. Go for simple and proven.
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've never been a fan of storred procedures since they either push logic to the database or split it between the database and the application (or application server).
We have a new Object Relational Mapping forum for all questions of this type. You would get a better response there.
Dave
 
Marshall B Thompson
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm not advocating business logic in the stored procedures, but you should use them for CRUD operations. This is an ongoing debate. However; I contend that keeping sql out of the database and striving for database independence is not good. Tom Kyte makes the points brilliantly in his book, "Expert One on One Oracle". I won't repeat them here. See the first chapter (where he advocates using the database) for free in pdf form at: http://www.orafaq.com/books/samples.htm. Note that this first chapter will be good reading for Sybase, SQL Server,...etc developers. He compares the databases to make his points.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic