mybatis返回值类型总结

//返回Integer
<select id="getSpeedByLinkId" parameterType="java.lang.String" resultType="Integer">
SELECT speed from dws_tfc_state_speed_link_last_rt where link_id = #{linkId}
</select>
//返回Double类型
<select id="getTravelTimeByLinkId" parameterType="java.lang.String" resultType="Double">
SELECT travel_time from dws_tfc_state_speed_link_last_rt where link_id = #{linkId}
</select>
//返回String 类型
<select id="getSpeedByLinkId" parameterType="java.lang.String" resultType="String">
SELECT speed from dws_tfc_state_speed_link_last_rt where link_id = #{linkId}
</select>

记录笔记创建时间:2019-10-26

posted @ 2019-10-26 20:00  wk814007042  阅读(2272)  评论(0编辑  收藏  举报