0
hbm.xml 파일에 명명 된 쿼리를 추가 했으므로 아래 코드와 같이 작동하지 않습니다. hibernate 명명 된 쿼리와 비슷합니다.
<query name="ca.getChildCategories"><![CDATA[
from category as ca where ca.name like :name
]]></query>
및 것은
getHibernateTemplate().findByNamedQueryAndNamedParam("ca.getChildCategories" ,
new String[] { "name"},
new Object[] { likeKey});
응용 프로그램으로 호출 오전은 UP 할 수 없습니다. 어떤 도움을 주셔서 감사합니다.
stacktrace pls를 추가하십시오. 나는 당신의 클래스가'Category'가 아닌'category'라고 생각합니다. – Apostolos
'category ca where ca.name like : name'로 확인하십시오. – Apostolos
@Apostolos Thanks. 그게 내 실수 야. :) –