题目
数据库group by语句
select * from hb_student_info where card_id in(select card_id from hb_student_info group by card_id having count(card_id)>1)
我知道这句的功能是查找出card_id相同的纪录 具体是怎么实现功能的,count函数大于1是什么意思?
select * from hb_student_info where card_id in(select card_id from hb_student_info group by card_id having count(card_id)>1)
我知道这句的功能是查找出card_id相同的纪录 具体是怎么实现功能的,count函数大于1是什么意思?
提问时间:2020-11-06
答案
select card_id from hb_student_info group by card_id having count(card_id)>1group by 是按照card_id分组,配合having做条件筛选比如hb_student_info中数据如下:card_id 栏位1 栏位2 001 1 2001 2 2001 3 4002 4...
举一反三
我想写一篇关于奥巴马的演讲的文章,写哪一篇好呢?为什么好
奥巴马演讲不用看稿子.为什么中国领导演讲要看?
想找英语初三上学期的首字母填空练习……
英语翻译
1,人们染上烟瘾,最终因吸烟使自己丧命.
最新试题
- 1为什么球形建筑和三角形建筑很坚固
- 2求ADFE的面积.三角形ABC面积=12.D为AB的中点..AE=2EC
- 3one and half a minute’s还是one and half a minutes’
- 4太阳、地球、月亮的年龄分别是多少?请详细说说到底是怎么算出来的?
- 51.14.75-(2又4/7-1又1/4)
- 6一个质量为m的质点以速度v0做匀速运动,某一时刻开始受到恒力F的作用,质点的速度先减小后增大,其最小值为v0/2.质点从开始受到恒力作用到速度减至最小的过程中 ( AD)
- 7They often go there with their books.(对划线部分提问)划线部分:their
- 8居民使用英语,大多属于白色人种的发达国家是( ) A.俄罗斯 B.法国 C.美国 D.巴西
- 9厨房玻璃,墙面上有许多小油滴,这些油滴形成包含物态变化是什么
- 10用什么词形容瀑布
热门考点