Estou tentando utilizar, mas dá erro
Parte Java
Map<String, Object> params = new HashMap<String, Object>();
List<String> aco = new ArrayList<String>();
StringBuilder filtro = new StringBuilder();
for (String s : stringSeparado) {
aco.add(s);
}
params.put("filtroAcoNotIn", aco);
parte xml
<isNotNull prepend="and" property="filtroAcoNotIn"> <iterate property="filtroAcoNotIn" open="('" close="')" conjunction=", "> #filtroAcoNotIn[]# </iterate> </isNotNull> <isNotNull prepend="and" property="filtroAcoIn"> <iterate property="filtroAcoIn" open="('" close="')" conjunction=", "> #filtroAcoIn[]# </iterate> </isNotNull>
Este erro:
00000023 SystemErr R java.lang.RuntimeException: Error executing query[listGusaConvertedor] with parameters[{corrida=null, dataInicial=Tue Jan 01 11:21:40 BRST 2019, filtroAcoNotIn=[9254S], dataFinal=Tue Jan 01 11:21:40 BRST 2019, filtroAcoIn=null}]: --- The error occurred while applying a parameter map. --- Check the listGusaConvertedor-InlineParameterMap. --- Check the parameter mapping for the 'filtroAcoNotIn[0]' property. --- Cause: java.sql.SQLException: Índice de coluna inválido