1. Index:Dictionary to get the directory, easy to find data.Principle: Store column information in its associated files, which are stored in an easy-to-retrieve manner such as B-tree, hashClassification of indexes:Normal all: Name, can only help
Create databases Mysql> Show CREATE Database oldboy\g1. Row ***************************Database:oldboyCreate database:create Database ' Oldboy '/*!40100 DEFAULT CHARACTER SET UTF8 */1 row in Set (0.00 sec)Establish a GBK character set database named
Reference Link: https://www.cnblogs.com/jhy-ocean/p/5560857.htmlMySQL timestamp involves a functionDate_format (date, format) function, MySQL date format function date_format ()Unix_timestamp () functionStr_to_date (str, format)
The current online database, divided into the main from two libraries, from the library to do more time-consuming statistical analysis of data.Today top a bit from the library server, found that mysqld for a long time to occupy the 105% CPU, at
Some information about MySQL Gtid
Gtid Persistent Media has two, one is table mysql.gtid_executed, the other is Binlog log.
The Gtid information in table mysql.gtid_executed tables is not updated in real time and is only recorded in table
Ps-ef|grep MySQLThere is no MySQL process in the found, so reboot.Service Mysqld Start ErrorViewing the error logTail-100/usr/local/mysql/var/iz11yohng9az.err (host name. Err)180223 15:31:51 Mysqld_safe starting mysqld daemon with databases from/usr/
1.MySQL conflict from library data causes synchronization to stopShow Slave Status Errorand show Slave status\gSlave_IO_Running: YesSlave_SQL_Running: NOSeconds_Behind_Master: NULLLast_Error:Error ‘Can’t create database ‘linzhongniao’;database
Mysql-proxy for read-write separationNeed to configure Master-slave synchronization: Five steps to complete MySQL master-slave replication主服务器Master:192.168.179.146从服务器Slave:192.168.179.147调度服务器MySQL-Proxy:192.168.179.142Download Mysql-proxyThe
A system database
Two database operations
Three-Name specification
Four user rights
Five. Change the password
Six forgot Password
Seven Chinese garbled problem
I. System database
INFORMATION_SCHEMA: Virtual
Allowed to connect to this MySQL server workaroundERROR 1130:host ' 192.168.1.3′is not allowed to connect to this MySQL server which is telling you that you do not have permission to connect the specified IP to the host, let's look at the workaround
How the database is backed up热备份:不影响业务的正常读写温备份:对表加锁,只允许对数据库进行读操作冷备份:业务暂停物理备份:备份mysql相关的数据文件逻辑备份:将数据从mysql中导出来,一般是一个sql文件(无索引数据)全备份:完全备份增量备份:针对上一次备份进行叠加差异备份:针对上一次完全备份,选择差异进行备份Using mysqldump BackupLogical backup, single process (slow), lock table
In MySQL, after a transaction commits, it is necessary to write undo, write Redo, write binlog, write data files, and so on. In this process, crash may occur at a certain step, which may result in inconsistent master-slave data. To avoid this
A stored procedure, which can be understood as a logical SQL statement.Advantage: Execution is very efficient, and stored procedures are performed on the server side of the database.Disadvantage: The portability is poor, and the stored procedures of
The effect is, with 2/8 principles, M.F.B. s to solve most things. So kick, limited to the overall adjustment, not involved in specific details.1, InnoDBUsing the InnoDB engine2, Innodb_buffer_poolAdjust and innodb about the parameters, as much as
Created: 2018/02/12In fact, many error messages, online search solutions to try and report other errors. So just put a few mistakes, sort the parts successively.Error 1:error! The server quit without updating PID fileError 2:Can ' t connect to local
Use mysqldump to back up and restore the database,
Database storage engine: InnoDB
Enable binlong1. Restore the database accidentally deleted to the latest status
1. Back up the database
mysqldump -A -F -uroot -p --master-data=2 --single-transaction
The default setting method for datetime type in mysql, mysqldatetime
An error occurred while modifying the default datetime value through the navicat client.
The field type of the database table is datetime. The default value is NULL. When the
In-depth understanding of SQL injection and SQL
1. What is SQL injection )?
SQL injection is an attack method that adds SQL code to input parameters and passes it to the SQL Server for parsing and execution.
2. How to generate it?
Web developers
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service