以hql举列更多的查帮助
// 使用List为参数作为条件结果
List<Integer> lst = new ArrayList<Integer>();
lstadd();
lstadd();
lstadd();
String hql = from Students s where sSId in (:lst);
Query q = sessioncreateQuery(hql);
qsetParameterList(lstlst);
// 以一个实类作为参数条件
hql = from Students s where sclass=:class;
qsetEntity(classsessionget(Classclass));
// 根据给的参数匹配对应的类型Type hiberntae里的类
hql = from Students s where sSId=? or sSName=?;
Query q = sessioncreateQuery(hql);
qsetParameters(new Object [] { update }new Type [] { new IntegerType()new StringType() });