sql语句

12312313aaaaaa 2018-02-07 10:01:47




这张表里ID包含fatherID的就去掉,也就是去掉生产和没有fatherID的动态,求语句
...全文
343 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
12312313aaaaaa 2018-02-07
  • 打赏
  • 举报
回复
谢谢
中国风 2018-02-07
  • 打赏
  • 举报
回复
取没有下级的记录? e.g.
select * from BCModule as a where not exists(select 1 from BCModule where fatherID=a.ID)

27,579

社区成员

发帖
与我相关
我的任务
社区描述
MS-SQL Server 应用实例
社区管理员
  • 应用实例社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧