Announcement Announcement Module
Collapse
No announcement yet.
HibernateTemplate need to import net.sf.hibernate.Hibernate? Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • HibernateTemplate need to import net.sf.hibernate.Hibernate?

    Hi ....l have a question.

    Below is the example from the Spring Reference Documentation Version 1.1 , pg 104

    public class ProductDaoImpl extends HibernateDaoSupport implements ProductDao {
    public List loadProductsByCategory(String category) {
    return getHibernateTemplate().find(
    "from test.Product product where product.category=?", category,
    Hibernate.STRING);
    }
    }

    Notice that "Hibernate.STRING" in the code , but l found no "net.sf.hibernate.Hibernate" import in the HibernateTemplate.java ,
    it suppose HibernateTemplate do the import , Right ?

  • #2
    Yes it should do the import.

    Comment

    Working...
    X