BETWEEN ADN 查询
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了BETWEEN ADN 查询相关的知识,希望对你有一定的参考价值。
语法:SELECT 字段名1, 字段名2, ...... , 字段名n FROM 表名 WHERE 查询条件 BETWEEN ... AND ... ;
mysql> SELECT f_name, f_price FROM fruits WHERE f_price BETWEEN 2.00 AND 10.20 ; +------------+---------+ | f_name | f_price | # 查询价格在2.00到10.20元之间的水果名称和价格 +------------+---------+ | apple | 5.20 | | apricot | 2.20 | | blackberry | 10.20 | | berry | 7.60 | | xxxx | 3.60 | | melon | 8.20 | | cherry | 3.20 | | lemon | 6.40 | | xbabay | 2.60 | | coconut | 9.20 | | grape | 5.30 | | xbababa | 3.60 | +------------+---------+
mysql> SELECT f_name, f_price FROM fruits WHERE f_price NOT BETWEEN 2.00 AND 10.20 ; +--------+---------+ | f_name | f_price | # 查询价格不在2.00到10.20元之间的水果名称和价格 +--------+---------+ | orange | 11.20 | | mango | 15.70 | | xxtt | 11.60 | | banana | 10.30 | +--------+---------+
以上是关于BETWEEN ADN 查询的主要内容,如果未能解决你的问题,请参考以下文章
[工作积累] UE4 并行渲染的同步 - Sync between FParallelCommandListSet & FRHICommandListImmediate calls(代码片段
SQL Server 查询使用 BETWEEN 过滤器带来不匹配的数据
查找与排序算法(Searching adn Sorting)