hql query : sum of two sub-select

隐身守侯 提交于 2019-12-12 04:10:02

问题


what's wrong with this HQL query :

select (
( select sum(base)/8 FROM com.agitech.erp.model.rhp.RhpEmployeRubric where ...)
 +
 ( select sum(base)/8 FROM com.agitech.erp.model.rhp.RhpEmployeRubric where ...)
 )

Having the exception :

unexpected end of subtree

i also try

select ( select sum(base)/8 FROM RhpEmployeRubric where ...) as sum1, 
       ( select sum(base)/8 FROM RhpEmployeRubric where ...) as sum2

same exception !

来源:https://stackoverflow.com/questions/23303315/hql-query-sum-of-two-sub-select

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!