//关联查询
红色是表
蓝色是别名
绿色是字段列
WHERE salecustomers.OID=saleproduct.SPOID and salecustomers.OID=#{oId};
</update>
//查询两个表所有
select * from salecustomers sc inner join saleproduct sp on sc.oId = sp.spOId where sc.del_Flg = #{del_Flg}
//修改两个表的内容
<update id="SaleCustomersAndProductDel" >
UPDATE salecustomers,saleproduct
SET salecustomers.DEL_FLG=#{del_Flg},saleproduct.DEL_FLG=#{del_Flg}WHERE salecustomers.OID=saleproduct.SPOID and salecustomers.OID=#{oId};
</update>