现在需要查询unit表中,在information表中有的unit_name,是否存在重复的数据。以下哪些逻辑可以实现?
A. select name,count(*) from unit u where u.name in (select unit name from informati on i where i.unit name = u.name)group by u.name having count(*) > 1; 。
B. select name,count(1) from unit u join inf ormation i on u.unit name=.unit name group by name where count(1) >1;
C. select name,count(*) from unit u where exists (select 1 from information i where i.unit_name = u.name)group by name having count(*) > 1;
D. select name,count(1) from unit u join inf ormation i on u.unit name=.unit name :
score表中存储了学生的学号、课程号、平时成绩和期末成绩,如果需要查询学号分别为的1111、2222和3333的学生学号、课程号、平时成绩和期末成绩。以下逻辑中可以实现的是?
A. select studentno, courseno, daily, finalfrom score where studentno ='1111' and studentno ='2222' and studentno ='3333');
B. select studentno, courseno, daily, finalfrom score where studentno in ('1111' .2222'3333"*);
C. select studentno, courseno, daily, finalfro score where studentno>=111;
D. select studentno, courseno, daily, finalfrom score where studentno = '1111' or stude ntno = 2222' or studentno = 33331):