Caused by: java.lang.IllegalArgumentException: org.hibernate.hql.internal.ast.QuerySyntaxException: Unable to locate appropriate constructor on class [com.icreate.xxxx.service.dto.xxxxxxx]. Expected arguments are: java.util.Date, java.lang.String, java.lang.String, long, double, double, double, double, double, double, double, double, double, double, long, double, long, double, long, double, long, double, long, double, long, double, long, double, long, double, double, long, double, long, double, long, double, long, double, long, double, double, double, double, double [SELECT new com.icreate.xxxx.service.dto.xxxxx(ls.xxx.starttime,ls.time.city,ls.timeCityy.sceneName,ls.cellCount,ls.lteUpFlow,ls.lteDownFlow,ls.lteFlow,ls.lteRadioConnectRate,ls.lteRadioDropRate,ls.lteUpPrbAvgRate,ls.lteAvgRate,ls.lteRate,ls.lteAvg,ls.lteRate,ls.lteCount,ls.lteHighFlowCellRate,ls.lteLowFlowCellCount,ls.LowFlow,ls.lteHigh,ls.lteHighDropCellProportion,ls.lteHighLoadCellCount,ls.lteHighLoadCellProportion,ls.lteUpPrbAvgUseRateHighCellCount,ls.lteUpPrbAvgUseRateortion,ls.lount,ls.CellProportion,ls.lteUpdownPrbAvgUseunt,ls.lteUrtion,ls.ltexnt,ls.lnectHighortion,ls.volteTraffic,ls.volteLoount,ls.volteLportion,ls.volteHiCount,ls.volteHighDropCaltion,ls.volteount,ls.voltCoportion,ls.voCount,ls.voltageCellProportion,ls.volteEsrvccSwitchSuccessRateLowCellCount,ls.volteEsrvccSwitchSuccessRateLowCellProportion,ls.voRate,ls.volteErabDropRate,ls.volteRate,ls.volteRate) FROM com.icreate.monitor.mapping.lte.entity.scene_indicator.DayAgg ls where ls.tiKey.starttime >= :starttime and ls.timeKey.starttime <= :endTime]
at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:133)
at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:157)
at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:164)
at org.hibernate.internal.AbstractSharedSessionContract.createQuery(AbstractSharedSessionContract.java:670)
at org.hibernate.internal.AbstractSessionImpl.createQuery(AbstractSessionImpl.java:23)
at sun.reflect.GeneratedMethodAccessor56.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.orm.jpa.ExtendedEntityManagerCreator$ExtendedEntityManagerInvocationHandler.invoke(ExtendedEntityManagerCreator.java:350)
at com.sun.proxy.$Proxy93.createQuery(Unknown Source)
at org.springframework.data.jpa.repository.query.SimpleJpaQuery.validateQuery(SimpleJpaQuery.java:87)
... 87 common frames omitted
这种情况,如果是使用了Lombok的话,那就是类中字段的物理排序有问题,字段的排序决定了构造函数参数的顺序。
类字段的物理排序必须与SELECT子句的顺序相匹配