如果我使用java执行以下命名查询,则我的查询返回零行。但是当我在sql developer中运行相同的查询时,我得到了一行。
<sql-query name="fetchMaxLoanAmountWithoutSuburb" cacheable="true">
<return-scalar column="maxLoanAmount" type="string" />
SELECT MAX_LOAN_AMOUNT "maxLoanAmount"
FROM CZ_SC_OR_MLS_MAX_LOAN_AMOUNT x, CZ_SC_OR_LOCATION_SUBURB y, CZ_SC_OR_STATE_ZONE z
WHERE y.POSTCODE in (:postalCode)
and y.STATE = z.STATE
and y. CATEGORY = z.CATEGORY
and z.ZONE = x.ZONE
and x.PRODUCT_TYPE = :productType
and x.DOC_TYPE = :docType
and x.PROPERTY_TYPE = :propertyType
and x.MIN_LVR_PCT <= (:minlvrPercentage)
and x.MAX_LVR_PCT >= (:maxlvrPercentage)
order by to_number(MAX_LOAN_AMOUNT)
</sql-query>
请告诉我是否可以在命名查询中使用“in”?请给我一个解决方案。