SQL的范围语句 between and

选取ID在1-5的所有用户

select * from [user] where id between 1 and 5

选取ID不在1-5的所有用户

select * from [user] where id not between 1 and 5

 

posted @ 2009-12-10 11:02  王翔(kingfly)  阅读(727)  评论(0编辑  收藏  举报