sql

  

 

top:

   sql server:   top

   MySQL:

      SELECT column_name(s)
      FROM table_name
      LIMIT number

 


distinct:

   返回唯一值

 

where 和 order by:

order by 应放于where之后

 

空值检查

is null

is not null

 

计算次序

使用圆括号

 

IN

可以包含其他select语句

 

通配符

http://www.w3school.com.cn/sql/sql_wildcards.asp

 通配符 描述

% 替代一个或多个字符
_ 仅替代一个字符
[charlist] 字符列中的任何单一字符
[^charlist] 不在字符列中的任何单一字符
或者
[!charlist]

 

 concat

   select top 1 concat(newsclass, '_', newsscope) as newcol from news_title_70

 

 

 

 


http://www.w3school.com.cn/sql/sql_top.asp

 

posted @ 2016-08-01 09:46  搜索技术  阅读(138)  评论(0编辑  收藏  举报