GBase 8s
其他
问答

GBase8sV8.8_TL_3.5.1_3X2_1_8fbc0b降级到GBase8sV8.8_AEE_3.3.3_1X1_3_9fa1c3时,批量插入不能正常使用了

发表于2025-05-22 13:42:38129次浏览4个评论

为提高效率,提问时请提供以下信息,问题描述清晰可优先响应。

【GBase版本】:GBase8sV8.8_AEE_3.3.3_1X1_3_9fa1c3

【问题描述】*:

GBase8sV8.8_TL_3.5.1_3X2_1_8fbc0b降级到GBase8sV8.8_AEE_3.3.3_1X1_3_9fa1c3时,批量插入不能正常使用了,如
<insert id="batchUserPost">
    insert into sys_user_post(user_id, post_id) values
    <foreach item="item" index="index" collection="list" separator=",">
       (#{item.userId},#{item.postId})
    </foreach>
</insert>
会直接报错

The error may involve compliance.culture.system.mapper.SysUserPostMapper.batchUserPost
The error occurred while executing an update
SQL: insert into sys_user_post(user_id, post_id) values (?,?) , (?,?)
Cause: java.sql.SQLException: 发生语法错误。

评论

登录后才可以发表评论
用户头像
liaosnet发表于 1年前
333不支持多values语法,该功能在350中增加。
最佳回答
用户头像
应钟发表于 1年前
@liaosnet:好吧
用户头像
应钟发表于 1年前
@liaosnet:好的谢谢
shepherd发表于 2个月前
等答案了啊。