openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Toffetti <>
Subject Re: Looking for advice on JPA based DAO
Date Thu, 16 Apr 2009 12:27:51 GMT

    Thanks for sharing this. In my case, I believe I still need DAO, see (quoted from [1]:

"...The usage cannot be simpler. The EntityManager will be just injected
to the bean-class...The DAO pattern is actually no more interesting for
general data access, but is still needed to access data from stored
procedures, flat files etc..."

    I don't do any **QL, whatever is more complex than simple POJO CRUD, I do it with proper
SQL in stored procedures. I like JPA a bit more than other ORM, but I still see it lacking
in this regard.
    I just DON'T WANT to invoke a callable statement or named query in my business code, that's
why I need a DAO layer. This is what I want to do in my business layer:

    Collection<SalesReportLine> reportItems = SalesReportLineDAO.query('2009-04-16');

    I hope my motivation is clear, anyway I'll gladly hear any argument against what I'm trying
to do and proposes a better alternative.



De: Pinaki Poddar (via Nabble) <>
Para: Daniel Toffetti <>
Enviado: jueves 16 de abril de 2009, 1:51:16
Asunto: Re: Looking for advice on JPA based DAO

  Or may be with JPA, DAO is no more a useful pattern? 
  I tend to align with Adam Bien's view [2] in this ongoing debate [1]. 


Daniel Toffetti wrote:
Hi all, 

    I'm looking for a JPA based DAO solution with minimal dependencies on other libraries.
So far I've found lots of implementations based on JPA "and" Spring, Hibernate, both of them,
TopLink, etc. 
    I would like to know if there is any standard way of doing it, or reference implementation
(even small, unfinished open source), or else if it's worth to attempt to do it. 
    Having seen so many DAO libraries and wrappers, so many articles and blog posts everywhere,
I must admit that I'm confused. Any advice is welcomed !! 


Pinaki Poddar            
OpenJPA PMC Member/Committer 
JPA Expert Group Member

This email is a reply to your post @
You can reply by email or by visting the link above.

      Yahoo! Cocina
Recetas prácticas y comida saludable
View this message in context:
Sent from the OpenJPA Users mailing list archive at

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message