Any discuss group about Hibernate, Spring?

Discussion in 'Java' started by RC, Mar 12, 2008.

  1. RC

    RC Guest

    Our office soon is going to replace
    JDBC with Hibernate. I am new to Hibernate.
    I try to follow the tutorial from Hibernate 3.2 doc/reference/
    I am stop in chapter 1, wouldn't get the same results as the tutorial!

    BTW, what is the relationship between Spring and Hibernate?
    Do we need both of them to replace JDBC?

    I program with JDBC for many years, feel comfortable with it.
    JDBC requires you well know about SQL. Hibernate doesn't require
    a programmer know about SQL. Is this a great advantage?
     
    RC, Mar 12, 2008
    #1
    1. Advertising

  2. RC

    Lew Guest

    RC wrote:
    > Our office soon is going to replace
    > JDBC with Hibernate. I am new to Hibernate.
    > I try to follow the tutorial from Hibernate 3.2 doc/reference/
    > I am stop in chapter 1, wouldn't get the same results as the tutorial!


    > BTW, what is the relationship between Spring and Hibernate?
    > Do we need both of them to replace JDBC?



    You don't need Spring to run Hibernate, but it helps, and it has other
    strengths besides. But Hibernate does not replace JDBC - it uses JDBC.

    > Hibernate doesn't require
    > a programmer know about SQL. Is this a great advantage?


    No, it's a huge disadvantage. Anyone who thinks they can use a SQL-based
    RDBMS without knowing SQL is hurting themselves.

    Hibernate, and JPA generally, have strengths in managing that SQL, but by no
    means should anyone think that they obviate the need for knowing how to use a
    DBMS.

    BTW, since mostly the same people read the three groups to which you
    cross-posted, you should set followup to just one. Cross-posting gives you no
    advantage in this instance, and might irritate some folks.

    --
    Lew
     
    Lew, Mar 12, 2008
    #2
    1. Advertising

  3. RC

    Arne Vajhøj Guest

    RC wrote:
    > Our office soon is going to replace
    > JDBC with Hibernate.


    No you will replace direct JDBC usage with Hibernate. Hibernate
    uses JDBC.

    > BTW, what is the relationship between Spring and Hibernate?


    None.

    Spring is a IOC/DI framework.

    Hibernate is an ORM.

    > Do we need both of them to replace JDBC?


    They don't.

    It is one of:

    your code----JDBC driver----database
    your code----Hibernate----JDBC driver----database
    your code----Spring----JDBC driver----database
    your code----Spring----Hibernate----JDBC driver----database

    > I program with JDBC for many years, feel comfortable with it.
    > JDBC requires you well know about SQL. Hibernate doesn't require
    > a programmer know about SQL. Is this a great advantage?


    It is an advantage that Hibernate works at a higher abstraction
    level and saves some trivial code.

    I will assume that your Java programmers did not have any
    problems with the simple SQL needed for CRUD.

    Besides you get HQL with Hibernate.

    :)

    Arne
     
    Arne Vajhøj, Mar 13, 2008
    #3
  4. RC

    Markus Tazl Guest

    On 12 Mrz., 14:10, RC <> wrote:
    > Our office soon is going to replace
    > JDBC with Hibernate. I am new to Hibernate.
    > I try to follow the tutorial from Hibernate 3.2 doc/reference/
    > I am stop in chapter 1, wouldn't get the same results as the tutorial!
    >
    > BTW, what is the relationship between Spring and Hibernate?
    > Do we need both of them to replace JDBC?
    >
    > I program with JDBC for many years, feel comfortable with it.
    > JDBC requires you well know about SQL. Hibernate doesn't require
    > a programmer know about SQL. Is this a great advantage?


    Hi RC,

    in addition to the excellent answers given by Lew and Arne : for a
    first introduction on Hibernate and Spring you could give two books
    from O'Reilly a try.

    http://www.oreilly.com/catalog/hibernate/index.html
    http://www.oreilly.com/catalog/springadn/index.html

    In my opinion they are both helpfull for beginners just to get an idea
    what it's all about.

    If you are familiar with Eclipse you could check out
    http://www.myeclipseide.com/documentation/quickstarts/hibernateandspring/

    best regards,
    Markus Tazl

    P.S. Even there is no relationship between Spring and Hibernate using
    them together can make life easier ;-)
     
    Markus Tazl, Mar 15, 2008
    #4
  5. RC

    RC Guest

    Markus Tazl wrote:

    >
    > Hi RC,
    >
    > in addition to the excellent answers given by Lew and Arne : for a
    > first introduction on Hibernate and Spring you could give two books
    > from O'Reilly a try.
    >
    > http://www.oreilly.com/catalog/hibernate/index.html


    I bought this book, that book published in 2004, the examples in that
    book are Hibernate 2.2. Those examples are no longer true for Hibernate
    3.2.
    All packages have changed from net.sf. to org.hibernate.
    package hbm2java is no longer available in 3.2, so I really can't play
    around those examples.

    > http://www.oreilly.com/catalog/springadn/index.html


    I also bought this book, but have start read it, yet.
    >
    > In my opinion they are both helpfull for beginners just to get an idea
    > what it's all about.
    >
    > If you are familiar with Eclipse you could check out
    > http://www.myeclipseide.com/documentation/quickstarts/hibernateandspring/


    Very good site, I'll learn from there.
     
    RC, Mar 17, 2008
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    0
    Views:
    679
  2. rmn190
    Replies:
    2
    Views:
    2,404
    Arne Vajhøj
    Jan 10, 2008
  3. Goldfish
    Replies:
    1
    Views:
    782
    Goldfish
    Nov 6, 2008
  4. Amit Jain
    Replies:
    7
    Views:
    3,337
    Amit Jain
    Apr 27, 2009
  5. Shyam
    Replies:
    1
    Views:
    325
    Daniele Futtorovic
    Sep 26, 2012
Loading...

Share This Page