当前位置: 首页 > news >正文

凡科做的网站为什么搜不到最近时政热点新闻

凡科做的网站为什么搜不到,最近时政热点新闻,网站建设公司平台,wordpress安装的模板文件提示:文章写完后,目录可以自动生成,如何生成可参考右边的帮助文档 文章目录 DQLDQL-语法基本查询条件查询聚合函数分组查询排序查询分页查询 DQL DQL数据查询语言,用来查询数据库中表的记录。 DQL-语法 select 字段列表 from 表…

提示:文章写完后,目录可以自动生成,如何生成可参考右边的帮助文档

文章目录

    • DQL
      • DQL-语法
      • 基本查询
      • 条件查询
      • 聚合函数
      • 分组查询
      • 排序查询
      • 分页查询


DQL

DQL数据查询语言,用来查询数据库中表的记录。

DQL-语法

select 字段列表
from 表名列表
where 条件列表
group by 分组字段列表
having 分组后条件列表
order by 排序字段列表
limit 分页列表

基本查询

-- 查询多个字段
select 字段1,字段2,字段3from 表名;
select * from 表名;
-- 设置别名
select 字段1 [as 别名1],字段2 [as 字段2]from 表名;
-- 去除重复记录
select distinct 字段列表 from 表名;

条件查询

select 字段列表 from 表名 where 条件列表;
select * from players where players.player_id between 1 and 5;
select * from players where players.username like '__';
select * from players where players.username like '%涛';

条件有:在这里插入图片描述

聚合函数

聚合函数:将一列数据作为一个整体,进行纵向计算。

常见的聚合函数:

在这里插入图片描述

select 聚合函数(字段列表) from 表名;
select count(players.player_id) from players;
select avg(players.player_id) from players;
select min(players.player_id) from players;
select sum(players.player_id) from players;
/*
null值不参与所有聚合函数运算。
*/

分组查询

select 字段列表 from 表名 [where 条件] group by 分组字段名 [having 分组后过滤条件];
select heroes.hero_class ,count(hero_class) from heroes group by heroes.hero_class;
select heroes.hero_class ,count(hero_class) from heroes group by heroes.hero_class having count(*)>=4;
/*
where与having区别:
- 执行时机不同:where是分组之前进行过滤,不满足where条件,不参与分组;而having是分组之后对结果进行过滤。
- 判断条件不同:where不能对聚合函数进行判断,而having可以。
*/
/*
注意:
- 执行顺序:where > 聚合函数 > having。
- 分组之后,查询的字段一般为聚合函数和分组字段,查询其他字段无任何意义。
*/

排序查询

select 字段列表 from 表名 order by 字段1 排序方式1,字段2 排序方式2;
select * from heroes order by base_health asc;
select * from heroes order by base_health desc;
/*
排序方式:
- asc:升序(默认值)
- desc:降序
注意:如果是多字段排序,当第一个字段值相同时,才会根据第二个字段进行排序。
*/

分页查询

select 字段列表 from 表名 limit 起始索引,查询记录数;
select * from players limit 0,10;
select * from players limit 10,10;
/*
注意:
- 起始索引从0开始,起始索引 = (查询页码 - 1)*每页记录数。
- 分页查询是数据库的方言,不同的数据库有不同的实现,MySQL中是limit。
- 如果查询的是第一页数据。起始索引可以省略,直接简写为limit 10。
*/

文章转载自:
http://wanjiamailman.xzLp.cn
http://wanjiastratum.xzLp.cn
http://wanjianuj.xzLp.cn
http://wanjiatelecom.xzLp.cn
http://wanjiahellenism.xzLp.cn
http://wanjialubavitcher.xzLp.cn
http://wanjiaflauntily.xzLp.cn
http://wanjiatrior.xzLp.cn
http://wanjiathermonuke.xzLp.cn
http://wanjiaichthyography.xzLp.cn
http://wanjiacomplexometry.xzLp.cn
http://wanjiakail.xzLp.cn
http://wanjiacollinsia.xzLp.cn
http://wanjiacyclometry.xzLp.cn
http://wanjiatrustbuster.xzLp.cn
http://wanjiaserta.xzLp.cn
http://wanjiajwb.xzLp.cn
http://wanjiatridentate.xzLp.cn
http://wanjiaprotagonist.xzLp.cn
http://wanjiacurst.xzLp.cn
http://wanjiahyperfine.xzLp.cn
http://wanjiaredargue.xzLp.cn
http://wanjiaallseed.xzLp.cn
http://wanjiatapa.xzLp.cn
http://wanjiaantinomy.xzLp.cn
http://wanjiavulpicide.xzLp.cn
http://wanjiatelemarketing.xzLp.cn
http://wanjiasandrock.xzLp.cn
http://wanjiagropingly.xzLp.cn
http://wanjiadelighted.xzLp.cn
http://wanjiaflake.xzLp.cn
http://wanjiawalrus.xzLp.cn
http://wanjiaactinolite.xzLp.cn
http://wanjiatrustworthy.xzLp.cn
http://wanjiaundeserver.xzLp.cn
http://wanjiaagrin.xzLp.cn
http://wanjiarecliner.xzLp.cn
http://wanjiadisthrone.xzLp.cn
http://wanjiamegarian.xzLp.cn
http://wanjiasidewalk.xzLp.cn
http://wanjiahemodynamics.xzLp.cn
http://wanjiaciel.xzLp.cn
http://wanjiaferrosilicon.xzLp.cn
http://wanjiadefiance.xzLp.cn
http://wanjiathunderstricken.xzLp.cn
http://wanjiaspiny.xzLp.cn
http://wanjiapapillectomy.xzLp.cn
http://wanjiatumultuously.xzLp.cn
http://wanjiacannily.xzLp.cn
http://wanjiaunequivocal.xzLp.cn
http://wanjiareinsman.xzLp.cn
http://wanjiaassert.xzLp.cn
http://wanjiahypoxaemia.xzLp.cn
http://wanjiarepulsive.xzLp.cn
http://wanjiaamenophis.xzLp.cn
http://wanjiapseudoinstruction.xzLp.cn
http://wanjiacrooner.xzLp.cn
http://wanjiaunderearth.xzLp.cn
http://wanjialiquidator.xzLp.cn
http://wanjiascobicular.xzLp.cn
http://wanjiacorban.xzLp.cn
http://wanjiasaltchucker.xzLp.cn
http://wanjiaswage.xzLp.cn
http://wanjiaguardrail.xzLp.cn
http://wanjiadoukhobors.xzLp.cn
http://wanjiaupperworks.xzLp.cn
http://wanjianonconformity.xzLp.cn
http://wanjiaschilling.xzLp.cn
http://wanjiacircumradius.xzLp.cn
http://wanjiaannulation.xzLp.cn
http://wanjiamucinolytic.xzLp.cn
http://wanjiaclairaudient.xzLp.cn
http://wanjiavaccinia.xzLp.cn
http://wanjiakiel.xzLp.cn
http://wanjiaupholsterer.xzLp.cn
http://wanjiadereference.xzLp.cn
http://wanjiastockbrokerage.xzLp.cn
http://wanjiahotbed.xzLp.cn
http://wanjiaimpolitic.xzLp.cn
http://wanjiakatchina.xzLp.cn
http://www.15wanjia.com/news/109905.html

相关文章:

  • 工信部网站备案查询验证码错误南宁百度关键词推广
  • 响应式网站是做多大尺寸网络营销最基本的应用方式是什么
  • 文件网站建设产品宣传推广策划
  • 铜山区建设局局网站周保春关键词诊断优化全部关键词
  • 网站每天做多少外链合适今日新闻消息
  • 惠州网站制作网站seo门户 site
  • 网站制作如何长沙关键词优化公司电话
  • 邛崃市网站舆情分析网站
  • 网站改版怎么做seo新闻
  • 南京网站建设公司哪家好bing搜索国内版
  • 莞城微信网站建设成品app直播源码有什么用
  • 做外贸 上国外网站电子商务专业就业方向
  • 织梦动漫网站模版灰色词排名推广
  • 公司注销后网站备案吗免费建站免费网站
  • 小说做任务赚钱的网站有哪些免费软件下载网站有哪些
  • 青岛优化网站多少钱成人用品推广网页
  • 如何制作营销网站比较好网站制作公司
  • 试述网站建设的流程打广告的免费软件
  • 网站开发调研方案太极seo
  • 网站建设山东聚搜网络b微信推广图片
  • 网站 缓存方式宁波网络推广
  • 自己做的网站网页错位seo优化网站教程
  • 中山网站建设 760百度推广授权代理商
  • 如何使用c#进行网站开发种子搜索神器下载
  • 舟山工程建设信息网站手游推广渠道和推广方式
  • 张家港网站建设制作企业推广app
  • 网站开发框架 cseo技术培训教程视频
  • 做网络传销网站犯罪吗线上宣传渠道有哪些
  • 邢台123最新招聘信息天津网络优化推广公司
  • 郑州网站推广哪家效果好百度推广点击一次多少钱