随笔分类 -  mysql

摘要:高性能MySQL之Count统计查询 https://blog.csdn.net/qq_15037231/article/details/81179383 MySQL 大表的count()优化 https://blog.csdn.net/u012674931/article/details/5271 阅读全文
posted @ 2020-12-24 16:42 tonggc1668 阅读(855) 评论(0) 推荐(0)
摘要:DBUtils使用query查询时出现无法将实体类属性赋值的问题 https://blog.csdn.net/m2606707610/article/details/90643240 阅读全文
posted @ 2020-10-16 10:19 tonggc1668 阅读(107) 评论(0) 推荐(0)
摘要:https://blog.csdn.net/lzw2016/article/details/89420391 阅读全文
posted @ 2020-07-24 19:13 tonggc1668 阅读(84) 评论(0) 推荐(0)
摘要:基于mysqldump快速搭建从库 https://blog.csdn.net/leshami/article/details/44994329 使用xtrbackup克隆从库 https://blog.csdn.net/bohai0409/article/details/52434406 使用xt 阅读全文
posted @ 2019-12-09 16:34 tonggc1668 阅读(209) 评论(0) 推荐(0)
摘要:http://blog.itpub.net/29773961/viewspace-1813501/ 阅读全文
posted @ 2019-01-31 12:36 tonggc1668 阅读(232) 评论(0) 推荐(0)
摘要:停止mysql服务windowsnet stop mysql (service mysqld stop win10不能用) linux /etc/init.d/mysqld stop 阅读全文
posted @ 2018-12-27 21:13 tonggc1668 阅读(503) 评论(0) 推荐(0)
摘要:mysql -u root -puse mysql; ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'root123';FLUSH PRIVILEGES; quit 阅读全文
posted @ 2018-12-27 21:13 tonggc1668 阅读(102) 评论(0) 推荐(0)
摘要:[client] default-character-set = utf8mb4 [mysql]# 设置mysql客户端默认字符集default-character-set=utf8mb4 [mysqld]# 服务端使用的字符集默认为8比特编码的latin1字符集character-set-clie 阅读全文
posted @ 2018-12-26 23:14 tonggc1668 阅读(142) 评论(0) 推荐(0)
摘要:https://blog.csdn.net/kernel_/article/details/53320498 阅读全文
posted @ 2018-12-26 22:54 tonggc1668 阅读(418) 评论(0) 推荐(0)
摘要:官网下载链接 https://dev.mysql.com/downloads/mysql/ 5.7下载链接 5.7.24zip解压版 64位 http://www.jb51.net/do/softdown.php?url=https%3A%2F%2Fcdn.mysql.com%2F%2FDownlo 阅读全文
posted @ 2018-12-23 22:51 tonggc1668 阅读(346) 评论(0) 推荐(0)
摘要:flush logs时做的操作: 对于一般查询日志和慢日志,先关闭文件再打开 对于binlog,关闭当前的,开始用下一个新的 用错误日志文件的话,先关闭再打开flush logs可以对一般查询日志,慢日志,错误日志 进行改名备份后重新生成文件(还是原来的名字) 阅读全文
posted @ 2017-12-11 20:16 tonggc1668 阅读(1296) 评论(0) 推荐(0)
摘要:select * from riv_test where a=3 for update;X锁 select * from riv_test where a=3 lock in share mode;S锁 阅读全文
posted @ 2017-12-09 15:30 tonggc1668 阅读(93) 评论(0) 推荐(0)
摘要:-- 查看被锁住的SELECT * FROM INFORMATION_SCHEMA.INNODB_LOCKS; -- 等待锁定SELECT * FROM INFORMATION_SCHEMA.INNODB_LOCK_WAITS; -- 查看事务SELECT * FROM INFORMATION_SC 阅读全文
posted @ 2017-12-09 15:16 tonggc1668 阅读(139) 评论(0) 推荐(0)
摘要:package com.yd.wmsc.util; import java.io.IOException; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.TimeUnit; public class Test { ... 阅读全文
posted @ 2017-11-13 19:04 tonggc1668 阅读(360) 评论(0) 推荐(0)
摘要:use wms; drop table if exists riv_outbound_notice_statistics_groupby_org;-- 增加出库通知单统计按机构分组表CREATE TABLE `riv_outbound_notice_statistics_groupby_org` ( 阅读全文
posted @ 2017-11-12 03:15 tonggc1668 阅读(210) 评论(0) 推荐(0)
摘要:CREATE DEFINER=`ggs`@`%` PROCEDURE `auto_create_salesman_location`()BEGINDECLARE table_prefix VARCHAR(100);DECLARE table_suffix BIGINT;DECLARE table_n 阅读全文
posted @ 2017-11-10 15:46 tonggc1668 阅读(117) 评论(0) 推荐(0)
摘要:use wms; drop table if exists riv_outbound_notice_statistics;-- 增加出库通知单统计表CREATE TABLE `riv_outbound_notice_statistics` ( `ONS_ID` int(10) NOT NULL AU 阅读全文
posted @ 2017-11-10 15:41 tonggc1668 阅读(134) 评论(0) 推荐(0)
摘要:package com.yundaex.wms.basicdata.dao.impl; import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.SQLException; import java.util.ArrayList; import java.util.List; import or... 阅读全文
posted @ 2017-09-27 17:10 tonggc1668 阅读(174) 评论(0) 推荐(0)
摘要:在某一个时间字段加索引,短的时间范围内查询,索引生效,为range。长时间范围,索引失效,查全表。 当索引查的数据量超过全表30%的数据,索引失效,会查全表。 阅读全文
posted @ 2017-09-26 14:48 tonggc1668 阅读(320) 评论(0) 推荐(0)
摘要:tab_user_profile 116行 riv_print_history_l 640746行 第一个用时10s,第二个用时0.6s 阅读全文
posted @ 2017-09-26 14:45 tonggc1668 阅读(137) 评论(0) 推荐(0)