显示所有具有以下位置的J,K和L库存箱位置
重新订购等级不超过5。

 select BinLocation, ReorderLevel
 from [Warehouse].[StockItemHoldings]
 where BinLocation like '%J%' or BinLocation like '%K%' or BinLocation like '%L%'
and ReorderLevel <= '5'


当前显示的整理水平高于5的结果。

最佳答案

您应在()之间加上或条件

select BinLocation, ReorderLevel
from [Warehouse].[StockItemHoldings]
where (BinLocation like '%J%' or BinLocation like '%K%' or BinLocation like '%L%' )
and ReorderLevel <= '5'

10-08 02:04