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

什么是网站空间如何制作企业宣传片视频

什么是网站空间,如何制作企业宣传片视频,线上编程课推荐哪一个,怎么查询企业邮箱超级聚合#xff0c;是在group by的基础上#xff0c;再次进行聚合。 它再次聚合的列#xff0c;是select中没有用到聚合函数的列。 文章目录 例子1解释例子2表以及数据 例子1 mysql SELECT year, country, product, SUM(profit) AS profitFROM salesGROUP BY year, c…超级聚合是在group by的基础上再次进行聚合。 它再次聚合的列是select中没有用到聚合函数的列。 文章目录 例子1解释例子2表以及数据 例子1 mysql SELECT year, country, product, SUM(profit) AS profitFROM salesGROUP BY year, country, product; ----------------------------------- | year | country | product | profit | ----------------------------------- | 2000 | Finland | Computer | 1500 | | 2000 | Finland | Phone | 100 | | 2000 | India | Calculator | 150 | | 2000 | India | Computer | 1200 | | 2000 | USA | Calculator | 75 | | 2000 | USA | Computer | 1500 | | 2001 | Finland | Phone | 10 | | 2001 | USA | Calculator | 50 | | 2001 | USA | Computer | 2700 | | 2001 | USA | TV | 250 | -----------------------------------mysql SELECT year, country, product, SUM(profit) AS profitFROM salesGROUP BY year, country, product WITH ROLLUP; ----------------------------------- | year | country | product | profit | ----------------------------------- | 2000 | Finland | Computer | 1500 | | 2000 | Finland | Phone | 100 | | 2000 | Finland | NULL | 1600 | | 2000 | India | Calculator | 150 | | 2000 | India | Computer | 1200 | | 2000 | India | NULL | 1350 | | 2000 | USA | Calculator | 75 | | 2000 | USA | Computer | 1500 | | 2000 | USA | NULL | 1575 | | 2000 | NULL | NULL | 4525 | | 2001 | Finland | Phone | 10 | | 2001 | Finland | NULL | 10 | | 2001 | USA | Calculator | 50 | | 2001 | USA | Computer | 2700 | | 2001 | USA | TV | 250 | | 2001 | USA | NULL | 3000 | | 2001 | NULL | NULL | 3010 | | NULL | NULL | NULL | 7535 | -----------------------------------解释 with rollup的工作原理就是在group by分组后进行超级聚合。 它针对的是在group by后面出现的列会把他们设置成null表示不对这一列进行统计。 从最左边开始找到不同的列值把他们设置成null 例子2 SELECT year, country, product, SUM(profit) AS profit FROM sales GROUP BY country, year, product 超级聚合 with rollup后 表以及数据 /* Navicat MySQL Data TransferSource Server : demo Source Server Version : 50733 Source Host : localhost:3306 Source Database : demoTarget Server Type : MYSQL Target Server Version : 50733 File Encoding : 65001Date: 2023-09-27 00:22:21 */SET FOREIGN_KEY_CHECKS0;-- ---------------------------- -- Table structure for sales -- ---------------------------- DROP TABLE IF EXISTS sales; CREATE TABLE sales (country varchar(20) DEFAULT NULL,year varchar(4) DEFAULT NULL,product varchar(20) DEFAULT NULL,profit int(4) DEFAULT NULL,id int(11) NOT NULL AUTO_INCREMENT,PRIMARY KEY (id) ) ENGINEInnoDB AUTO_INCREMENT11 DEFAULT CHARSETutf8;-- ---------------------------- -- Records of sales -- ---------------------------- INSERT INTO sales VALUES (Finland, 2000, Computer, 1500, 1); INSERT INTO sales VALUES (Finland, 2000, Phone, 100, 2); INSERT INTO sales VALUES (India, 2000, Calculator, 150, 3); INSERT INTO sales VALUES (India, 2000, Computer, 1200, 4); INSERT INTO sales VALUES (USA, 2000, Calculator, 75, 5); INSERT INTO sales VALUES (USA, 2000, Computer, 1500, 6); INSERT INTO sales VALUES (Finland, 2001, Phone, 10, 7); INSERT INTO sales VALUES (USA, 2001, Calculator, 50, 8); INSERT INTO sales VALUES (USA, 2001, Computer, 2700, 9); INSERT INTO sales VALUES (USA, 2001, TV, 250, 10);
http://www.hkea.cn/news/14518936/

相关文章:

  • dz网站如何搬家温岭专业营销型网站建设地址
  • 杨浦建设机械网站做好网络推广的技巧
  • 做外贸哪个网站看外汇秦皇岛市建设局官网
  • 随州学做网站培训体系搭建
  • 人防网站建设专门下软件的app
  • 三灶网站建设微网站建设的现状
  • 做推文封面的网站做视频网站需要什么
  • 网站后台功能模块设计网址免费制作app
  • 做网站百灵鸟网站的域名在哪里看
  • 自己做的网站不显示图片wordpress手机访问
  • 景区网站建设费用新网官方网站登陆
  • 新建网站推广网站建设 力洋网络
  • 太原深圳建设工程信息网站湖南省建设资源人才网站
  • 公司网站制作效果怎么样潜江资讯网
  • 南通装饰网站建设怎么用百度云做网站空间
  • 厦门专业网站设计公asp.net网站的数据库配置
  • 如何免费搭建自己的网站查查企业信息查询平台
  • 网上做兼职做网站wordpress主题 好的
  • 做 英语试题的网站硬件开发岗位要求
  • 成都建设银行合作装修网站星裕建设网站
  • 网站建设方案对比分析报告google登录入口
  • 网页欢迎页面设计广告网站建设网站排名优化
  • 乌海网站建设公司网站栏目收录
  • 51个人网站广州网站建设电话咨询
  • 网站制作公司中企动力推荐定制网站建设公司价格
  • 邢台移动网站建设费用wordpress侧边栏在哪
  • 怎么做 在线电影网站苏州调查公司电话
  • 如何做一个网站的seo郑州网站建设 个人工作室
  • 自建网站的好处企业商城网站开发建设
  • 吴志国网站建设工作室网站域名到期登不上是怎么回事