子查询where子句 [英] Subqueries where clause
本文介绍了子查询where子句的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我是sql的初学者。请有人解释(在哪里1< ..............)以下查询
SELECT salesman_id,name
FROM salesman a
WHERE 1<
(SELECT COUNT(*)
FROM customer
WHERE salesman_id = a.salesman_id);
我尝试了什么:
我尝试了不同的查询,但我不明白这个
I am beginner in sql. Please someone explain ( WHERE 1 < ..............) below query
SELECT salesman_id,name
FROM salesman a
WHERE 1 <
(SELECT COUNT(*)
FROM customer
WHERE salesman_id=a.salesman_id);
What I have tried:
I tried different query but I don't understand this
推荐答案
它选择所有拥有多个客户的销售人员。
It selects all salesmen that has more than one customer.
这篇关于子查询where子句的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文