1、jdbc配置
url增加allowMultiQueries=true
filters去除 wall
2、dataSource配置
<property name="proxyFilters">
<list>
<ref bean="wall-filter" />
</list>
</property>
<bean id="wall-config" class="com.alibaba.druid.wall.WallConfig">
<property name="multiStatementAllow" value="true" />
</bean>
<bean id="wall-filter" class="com.alibaba.druid.wall.WallFilter">
<property name="logViolation" value="true" />
<property name="throwException" value="false" />
<property name="dbType" value="mysql" />
<property name="config" ref="wall-config" />
</bean>
3、xml使用
insert into tab(****)
values
<foreach collection ="claimPolicys" item="claimPolicy" index= "index" separator =",">
(******)
</foreach>