查看是否有锁现象 ## 1. 看有没有锁等待 SHOW STATUS LIKE 'innodb_row_lock%'; ## 2. 查看哪个事务在等待(被阻塞了) USE information_schema SELECT * FROM information_schema.INNODB_TRX W ...
分类:
数据库 时间:
2020-07-10 20:42:20
阅读次数:
87
前言:我们都知道,binlog可以说是MySQL中比较重要的日志了,在日常学习及运维过程中,也经常会遇到。不清楚你对binlog了解多少呢?本篇文章将从binlog作用、binlog相关参数、解析binlog内容三个方面带你了解binlog。1.binlog简介binlog即binarylog,二进制日志文件。它记录了数据库所有执行的DDL和DML语句(除了数据查询语句select、show等),
分类:
数据库 时间:
2020-07-10 19:32:23
阅读次数:
72
第一种 concat select * from cat_table where cat_name like concat(#{catName},'%') --单个百分号 select * from cat_table where cat_name like concat(concat('%',#{ ...
分类:
数据库 时间:
2020-07-10 19:22:10
阅读次数:
83
Mysql超大分页怎么优化处理 1)数据库层面,这也是我们主要集中关注的(虽然收效没那么大),类似于 select * from table where age > 20 limit 1000000,10 这种查询其实也是有可以优化的余地的. 这条语句需要load1000000数据然后基本上全部丢弃 ...
分类:
数据库 时间:
2020-07-10 19:04:59
阅读次数:
69
1. DQL语言的学习 ① 基础查询 /* 语法: select 查询列表 from 表名; 特点: ① 通过select查询完的结果 ,是一个虚拟的表格,不是真实存在 ② 要查询的东西 可以是常量值、可以是表达式、可以是字段、可以是函数 ③ 可以没有from语句 ④ 先执行from语句,再执行se ...
分类:
数据库 时间:
2020-07-10 19:00:33
阅读次数:
69
1)count(*)会忽略所有的列,直接统计所有列数,不要使用count(列名),也就是不要使用count(1),count(id) 2)可以使用explain查询近似值,用近似值替代count(*) 3)使用缓存,记录总数 4)允许的话,把innodb改为myisam 5)SELECT (SELE ...
分类:
数据库 时间:
2020-07-10 18:48:16
阅读次数:
75
MacOSIDEA报svn:error:ThesubversioncommandlinetoolsarenolongerprovidedbyXcodeMacOS升级后出现xcrun:error:invalidactivedeveloperpath,missingxcrun1、重新安装xcodexcode-select--install2、安装svnbrewinstallsvn参考:https://
分类:
系统相关 时间:
2020-07-10 17:12:03
阅读次数:
75
1.html部分: <span id="s_address_sheng">省</span>: <select name="address_sheng" onchange="change('address','_sheng','_shi','')" id="address_sheng" style=" ...
分类:
Web程序 时间:
2020-07-10 15:39:05
阅读次数:
87
SELECT users.UserID AS Id, users.UserName, users.TrueName, users.Phone, users.Email, STUFF( ( SELECT ',' + roles.Description FROM Accounts_UserRoles u ...
分类:
其他好文 时间:
2020-07-10 15:11:25
阅读次数:
65
Mac配置前端开发环境及遇到的问题与解决方案 MacOS版本:10.15.3 一,安装brew 问题:curl: (7) Failed to connect to raw.githubusercontent.com port 443: Connection refused的解决办法 解决方案:打不开 ...
分类:
系统相关 时间:
2020-07-10 15:09:17
阅读次数:
107