一条sql关联删除多张表数据
2024-09-03 06:46:06
现有6张表存在关联关系,要删除主表则其他5张表关联数据也要一块删掉(单条sql多id批量删除)
delete
t1,t2,t3,t4,t5,t6
FROM
rmd_v AS t1
LEFT JOIN rmd_v1 AS t2 ON t1.uuid = t2.rvuuid
LEFT JOIN rmd_v2 AS t3 ON t1.uuid = t3.rvuuid
LEFT JOIN rmd_v3 AS t4 ON t1.uuid = t4.rvuuid
LEFT JOIN rmd_v4 AS t5 ON t1.uuid = t5.rvuuid
LEFT JOIN rmd_v5 AS t6 ON t1.uuid = t6.rvuuid
WHERE
t1.uuid in ('aaaab','aaaac')
最新文章
- StackExchange.Redis帮助类解决方案RedisRepository封装(基础配置)
- React Diff算法
- 使用Memberane Moniter监控HTTP &; SOAP requests
- React的双向绑定
- SASS 初学者入门
- php多文件上传数组 转换
- sql server 中一次insert 多条的写法
- 扩展欧几里德解的数量(51nod 1352)
- Javascript入门学习
- false等于0???
- html-----012---颜色的改变
- MSSQL 镜像
- Moon.Orm 5.0 (MQL版)
- org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.reflection.ReflectionException: There is no getter for property named '__frch_lableId_0' in 'class com.cd.entity.Page'
- $smary模板缓存
- CI框架剖析一
- Java代码编写的一般性指导
- Java_异常以及处理
- 小小知识点(四)——MATLAB如何画等高线图和线性规划约束方程
- JPype1使用总结
热门文章
- 全局唯一性ID生成方法小结
- 使用Docker构建基于centos7镜像的python环境
- Tomcat跨域
- SpringBoot项目 org.springframework.boot.context.embedded.EmbeddedServletContainerException: Unable to start embedded Jetty servlet container报错
- Jquery输入框焦点事件及鼠表事件汇总
- 洛谷 P2196 挖地雷
- java多线程之volatile关键字
- Codeforces Round #594 (Div. 1) Ivan the Fool and the Probability Theory
- csv文件——简单读操作01
- 网鼎杯-Fakebook-反序列化和SSRF和file协议读取文件