insert into jsh_material id, category_id, name, mfrs, model, standard, brand, mnemonic, color, unit, remark, img_name, unit_id, expiry_num, weight, enabled, other_field1, other_field2, other_field3, enable_serial_number, enable_batch_number, position, tenant_id, delete_flag, #{id,jdbcType=BIGINT}, #{categoryId,jdbcType=BIGINT}, #{name,jdbcType=VARCHAR}, #{mfrs,jdbcType=VARCHAR}, #{model,jdbcType=VARCHAR}, #{standard,jdbcType=VARCHAR}, #{brand,jdbcType=VARCHAR}, #{mnemonic,jdbcType=VARCHAR}, #{color,jdbcType=VARCHAR}, #{unit,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{imgName,jdbcType=VARCHAR}, #{unitId,jdbcType=BIGINT}, #{expiryNum,jdbcType=INTEGER}, #{weight,jdbcType=DECIMAL}, #{enabled,jdbcType=BIT}, #{otherField1,jdbcType=VARCHAR}, #{otherField2,jdbcType=VARCHAR}, #{otherField3,jdbcType=VARCHAR}, #{enableSerialNumber,jdbcType=VARCHAR}, #{enableBatchNumber,jdbcType=VARCHAR}, #{position,jdbcType=VARCHAR}, #{tenantId,jdbcType=BIGINT}, #{deleteFlag,jdbcType=VARCHAR}, update jsh_material set delete_flag='1' where 1=1 and ifnull(delete_flag,'0') !='1' and id in ( #{id} ) update jsh_material set unit_id = null where 1=1 and ifnull(delete_flag,'0') !='1' and id = #{id} update jsh_material set expiry_num = null where 1=1 and ifnull(delete_flag,'0') !='1' and id = #{id}