代码运行结果分析
criteria.add(Restrictions.eq("ready",1));
System.out.print(criteria.list());//[com.dao.survey@55c42b60]
Number totalNum = (Number)criteria.setProjection(Projections.rowCount()).uniqueResult();//【1】
不知道为什么,懂得说一下
代码运行结果分析
criteria.add(Restrictions.eq("ready",1));
System.out.print(criteria.list());//[com.dao.survey@55c42b60]
Number totalNum = (Number)criteria.setProjection(Projections.rowCount()).uniqueResult();//【1】
不知道为什么,懂得说一下