• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Junilu Lacar
Sheriffs:
  • Rob Spoor
  • Liutauras Vilda
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Piet Souris
  • Tim Holloway
  • Jj Roberts
  • Stephan van Hulst
Bartenders:
  • Himai Minh
  • Carey Brown
  • Frits Walraven

Hibernate Vs JDBC

 
Ranch Hand
Posts: 1491
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have Orcale 9i database. Can i replace Hibernate instead of jdbc? How it affects the performance of the System?
 
Ranch Hand
Posts: 1646
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hibernate will work fine with Oracle 9i (that's what my company uses).

Since Hibernate uses JDBC, with enough time, work, and craftiness you should be able to hand-code JDBC to be faster than Hibernate. The trick, however, is that with a sufficiently complex application, the risks of making a mistake with JDBC are greater than with a tool like Hibernate, JDO, TopLink, etc.

If your business logic modifies more than one object or different fields of the same object in different methods, optimizing JDBC becomes quite difficult and error prone. Hibernate helps out here by persisting object changes as a single unit, allowing some optimization (e.g. convert two updates to a user into a single SQL update).

I suggest reading some of the past messages in this forum to get a feel for the differences and whether or not Hibernate or a similar tool will be right for your application. There is no single answer.
 
Ranch Hand
Posts: 194
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by David Harkness:
There is no single answer.



The fact that there's no "perfect" data persistence technology that can be recommended for all types of application means you need to be careful (and maybe flexible).

You may find "Choosing a data persistence strategy useful"

http://www.codefutures.com/weblog/andygrove/archives/2005/01/choosing_a_java.html


Also, a comparison of the various technologies

http://www.codefutures.com/weblog/corporate/archives/2005/02/data_persistenc.html

Finally, you need to separate out your choice of technologies (JDBC, Hibernate, EJB CMP, etc) from best design practices (such as using Data Access Objects).
 
I don't even know how to spell CIA. But this tiny ad does:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
reply
    Bookmark Topic Watch Topic
  • New Topic