2017-01-25 31 views
-2

,我需要选择产品(自己的名字),价格有高于平均水平的价格,但价格比33不能运行mysql要求

我的请求记录:

select ProductName, Price 
from Products 
where Price>(select avg(Price) from Products) 
and 
Where Price < 33; 

这不是加工。为什么?

预先感谢您。

+0

“不工作” 不会有什么帮助。你有任何错误? – tadman

回答

0

删除重复where像这样:

select ProductName, Price 
from Products 
where Price > (select avg(Price) from Products) 
    and Price < 33;