我有以下 HQL 查询:
SELECT ita.invoiceType, ita.agreementNumber, itr.ruleCategory
FROM InvoiceTypeAgreements ita, InvoiceTypeRules itr
WHERE ita.invoiceType = itr.invoiceType
AND ita.agreementNumber IN (?1)
AND itr.ruleCategory IN (?2)
我query.getResultList()
用来从中获取值。我假设它正在返回一个,ArrayList<String[]>
但每当我尝试访问String[]
's 时,ArrayList<String[]>
我都会收到此错误:
java.util.concurrent.ExecutionException: javax.ejb.EJBException:
java.lang.ClassCastException: [Ljava.lang.Object; cannot be cast to [Ljava.lang.String;
不是ArrayList<String[]>
HQL 查询返回的内容吗?