MySQL binlog safe removal

1. Manually clear the Binlog fileTheoretically, you should add a configuration entry for the Binlog expiration time in the configuration file/etc/my.cnf, Expire_logs_days = ten. but without adding this, the disk has been eaten a lot as more and more

About MySQL Chinese garbled

The first step: Check the SQL script to see if the statement that created the database has a setting utf8:create the default character set UTF8;Step two: At the end of the statement that creates the table, add: Character set = UTF8; make the table

MySQL Insert 100,000 data time

Record one of my MySQL operation demo:Stored procedures:DROP PROCEDURE IF EXISTSMy_insert;CREATE PROCEDUREMy_insert ()BEGIN DECLARENint DEFAULT 1; Loopname:loopINSERT intoUser_info (Id,name,age,gender,address,tel)VALUES(N,'Lilis', -,2,'Xia sha,

MySQL Statement execution order

MySQL Statement execution orderThe MySQL statement is divided into 11 steps, as noted, the first execution is always the from operation, and finally the limit operation is performed. Each of these operations produces a virtual table that acts as a

mysql-views View

Views: A non-real-world table that contains complex queries can also be understood as a result of a query.Add a concept: Temporal table Query (subquery): Is to nest a query again in the query statement, and set the nested query aliasSELECT *

MySQL Partition description

When MySQL's total record count exceeds 1 million, performance can be significantly reduced, using a partitioning schemePartitioning allows multiple parts of a single table to be allocated across the file system according to the specified rules.

MySQL Stored Procedures-Summary Learning

Simple stored Procedure INSERT statementBEGIN INSERT into VALUES (ten,3,'2013-01-02',9); #RoauDtine Body goes here ... Select -- indicates the number of rows affected ENDSimple stored Procedure ifelse statement (UserID In,username is out)BEGIN

MySQL Common commands

EngineMyISAM emphasizes performance, faster than InnoDB, but does not provide transactional support, complex tasks, and associations. Supports table locks. Similar to Excel tables. The default mode when installing.InnoDB, supports external keys, can

Com.mysql.jdbc.Driver = = "Com.mysql.cj.jdbc.Driver

Error message:sqlsession [[email protected]] was wasn't registered for synchronization because synchronization are not active Loading class ' Com.mysql.jdbc.Driver '.This is deprecated. The new driver class is ' com.mysql.cj.jdbc.Driver '. The

MySQL Backup and recovery

MySQL Backup and recoveryBackup mysqldump-uroot-p-B test >test.sqlDescription: - p followed by the password, there is no space in the middle, B will also back up the databases, mysqldump out are some SQL statements, so with redirection symbols >

MySQL database automates full and incremental backups

MySQL database automates full and incremental backupsIncremental Backup, in order to enhancethe security and integrity of the MySQL database requires a backup of the data. The strategy we're using here is every Friday pm 5:30 A full backup; daily6: 0

Uninstall MySQL under Ubuntu

1. Delete MySQL1 sudo apt-get autoremove--purge mysql-server-5.02 sudo apt-get remove mysql-server3 sudo apt-get autoremove mysql-server4 sudo apt-get remove Mysql-common (very important)In fact, some of the above is redundant, it is recommended to

How to maintain data consistency when MySQL is backed up

MySQL data backup, the common way such as the following three, there may be many people on the backup data consistency is not clear 1, directly copy all files under the entire data directory to the new machine. The advantages are simple, fast,

Django link MySQL

1. Installation PreparationPip Install MySQLdbPIP3 Install Python-client2, do the data before the operation to avoid data lossVim settings.py#mysql DatabaseDATABASES = {' Default ': ' ENGINE ': ' Django.db.backends.mysql ', ' NAME ': ' Django ', '

Linux MySQL Chinese garbled

1, suddenly found that MySQL database has a Chinese garbled phenomenon, I want to completely solve the problemCheck the database settings, sure enough, the database is not specified in the configuration file encoding is UTF8 (mixed in English and

MySQL DUPLICATE KEY (merge) syntax

Previously used ms-sql need to merge tables with the merge syntax, after changing MySQL found no this syntax.Look for a bit of an alternative, it is very convenient.ALTER TABLEBrandADD UNIQUE(Code)ALTER TABLEbrand_tempADD UNIQUE(Brand_Code)INSERT

Mysql Multi-Instance implementation steps

Basic theory: The use of the same set of installers, different configuration files, different startup programs, different data directories. There are public resources, and there are private resources.Implementation steps:1, the normal installation

MySQL 5.7.18 Source Code Installation

1 Downloads1.1 Download URL: www.mysql.com1.2 Download method1.2.1 Enter the homepage, select DOWNLOADS , and we are in the download page. As shown in the download URL https://www.mysql.com/downloads/ 1.2.2 Go to the download page, you can see a

Find uncommitted MySQL Threads/transactions

Find the uncommitted MySQL thread/transaction:SELECT trx_id,trx_state,trx_started,trx_mysql_thread_id,current_timestamp-trx_started as RUN_TIME from Information_ Schema.innodb_trx;650) this.width=650; "src="

Remote Access to Mysql

Remote Access to Mysql At present, many Internet companies have become an unstoppable trend in using mysql databases, so what we often do at the beginning of the project is to find a Linux server, install mysql on the top, and then start importing

Total Pages: 3233 1 .... 2371 2372 2373 2374 2375 .... 3233 Go to: GO

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.