博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
SQLite中的表达式
阅读量:5249 次
发布时间:2019-06-14

本文共 839 字,大约阅读时间需要 2 分钟。

SQLite中的表达式

在SELECT的基本完整形式中,我们会看到几乎是所有的子句都会使用到表达式。以下是SQLite支持的表达式类型。

expr binary-op expr |                                                                                                                //二元运算符

expr [NOT] like-op expr [ESCAPE expr] |                                                                    //LIKE运算符,匹配模式的一种

unary-op expr |                                                                                                                 //一元运算符

( expr ) |                                                                                                                             //括号

column-name |                                                                                                                          //列名

table-name . column-name |                                                                                        //表名.列名

database-name . table-name . column-name |                                                                  //数据库名.表名.列名

literal-value |                                                                                                                     //字面量

parameter |                                                                                                                       //差数形式

function-name ( expr-list | * ) |                                                                                       //函数

expr ISNULL |                                                                                                                   //处理NULL值

expr NOTNULL |                                                                                                              //非空

expr [NOT] BETWEEN expr AND expr |                                                                      //范围

expr [NOT] IN ( value-list ) |                                                                                            //范围

expr [NOT] IN ( select-statement ) |                                                                              //范围

expr [NOT] IN [database-name .] table-name |                                                          //范围

[EXISTS] ( select-statement ) |                                                                                       //存在

CASE [expr] ( WHEN expr THEN expr )+ [ELSE expr] END |                                  //条件结果

CAST ( expr AS type )                                                                                                     //转换

本节将讲解这些表达式中最为常用的几种,如运算符、NULL的运算、参数形式、匹配模式、内建函数、条件结果等内容。

转载于:https://www.cnblogs.com/daxueba-ITdaren/p/9018642.html

你可能感兴趣的文章
bzoj3224 splay板子
查看>>
程序存储问题
查看>>
Mac版OBS设置详解
查看>>
优雅地书写回调——Promise
查看>>
android主流开源库
查看>>
AX 2009 Grid控件下多选行
查看>>
PHP的配置
查看>>
Struts框架----进度1
查看>>
Round B APAC Test 2017
查看>>
MySQL 字符编码问题详细解释
查看>>
perl 学习笔记
查看>>
31 Days of Windows Phone
查看>>
poj 1184(聪明的打字员)
查看>>
Ubuntu下面安装eclipse for c++
查看>>
C#压缩或解压(rar和zip文件)
查看>>
让IE浏览器支持CSS3圆角属性的方法
查看>>
巡风源码阅读与分析---nascan.py
查看>>
LiveBinding应用 dataBind 数据绑定
查看>>
Linux重定向: > 和 &> 区别
查看>>
nginx修改内核参数
查看>>