springmvc添加数据并返回主键,报错不支持java.lang.String类型 11
<!--添加数据返回主键--><insertid="insertforDictSingleId"parameterType="com.vo.DictSingle"><se...
<!-- 添加数据返回主键 -->
<insert id="insertforDictSingleId" parameterType="com.vo.DictSingle">
<selectKey keyProperty="dictSingleId" order="BEFORE" resultType="java.lang.String">
select uuid()
</selectKey>
insert into dict_single (dict_single_id, dict_single_content)
values (#{dictSingleId,jdbcType=VARCHAR}, #{dictSingleContent,jdbcType=VARCHAR})
</insert>
/*添加数据返回主键*/
String insertforDictSingleId(DictSingle record); 展开
<insert id="insertforDictSingleId" parameterType="com.vo.DictSingle">
<selectKey keyProperty="dictSingleId" order="BEFORE" resultType="java.lang.String">
select uuid()
</selectKey>
insert into dict_single (dict_single_id, dict_single_content)
values (#{dictSingleId,jdbcType=VARCHAR}, #{dictSingleContent,jdbcType=VARCHAR})
</insert>
/*添加数据返回主键*/
String insertforDictSingleId(DictSingle record); 展开
3个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询