题目:
当A=1时并且b不等于2也不能等于3的情况,请用and或or写出来
解:
(1)、select * from table1 where A=1 and b not in(2,3)
(2)、select * from table1 where A=1 and b<>2 and b<>3
select * from table1 where A=1 and b!=2 and b!=3——(这么写是错误的)
sql 中“不等于”用<>表示或者用not in 表示