随笔分类 - Hibernate 示例
摘要:hibernate.cfg.xml配置: org.hibernate.dialect.MySQLDialect jdbc:mysql://127.0.0.1/java?characterEncoding=utf-8 root root com.mysql.jdbc.Driver com.mysql.jdbc.Driver tru...
阅读全文
摘要:package com.etc.test; import java.util.Iterator; import java.util.List; import org.hibernate.Query; import org.hibernate.Session; import org.junit.Test; import com.etc.dao.HibernateSessionFactory;...
阅读全文
摘要:package com.etc.test; import java.util.List; import org.hibernate.Criteria;import org.hibernate.Session;import org.hibernate.criterion.DetachedCriteri
阅读全文
摘要:package com.etc.test; import java.util.List;import java.util.Properties; import org.hibernate.Query;import org.hibernate.SQLQuery;import org.hibernate
阅读全文
摘要:package com.etc.test;import java.util.List;import org.hibernate.Session;import org.hibernate.SessionFactory;import org.hibernate.cfg.Configuration;imp
阅读全文