openlayers 根據縮放層級給點要素新增聚合
阿新 • • 發佈:2020-12-17
set標籤用於更新語句,當同事要更新多個欄位時,我們需要留意當前是否是最後一個set,避免在後面出現,
符號,使用set標籤後可自動去除最後的逗號
mapper:
<update id="updateProductTest" parameterType="products"> update products <set> <if test="pname != null and pname != ''"> pname = #{pname}, </if> <if test="price != null and price > 0"> price = #{price}, </if> <if test="pdate != null"> pdate = #{pdate}, </if> <if test="cid != null and cid != ''"> cid = #{cid}, </if> </set> where pid = #{pid} </update>測試程式碼: