This article mainly introduces the MySQL slow query analysis method. Some days ago, I set a record to query SQL statements that are slower than 1 second in the MySQL database. There are several very well-configured methods, and the names of several
MySQL database is an open source database based on structured data. SQL statements are the core language of MySQL databases. However, when executing SQL statements in the MySQL database, you need to be careful with two traps.
Trap 1: NULL values are
DATETIME: A combination of date and time. The supported range is '2017-01-01 00:00:00 'to '2017-12-31 23:59:59 '. MySQL displays DATETIME values in 'yyyy-MM-DD HH: MM: ss' format, but allows values to be assigned to DATETIME columns using strings or
Mysql backup classification:Mysql Data Backup:Logical backup and physical backupMysql is classified by Dataset:Full backupIncremental BackupDifferential backupThese types are generally used in combination. For example, full backup can be performed
> PreparationTake MySQL as an example. Execute the following SQL statement to create a data table.Create table 't_ user '('Id' int (11) not null,'Name' varchar (50) default null,'Sex 'char (4) default null,'Age' int (11) default null,'Career'
Differences between MySQL auto-growth and Oracle sequence:Auto-increment can only be used for one field in the tableAuto-growth can only be assigned to a fixed field of a fixed table, and cannot be shared by multiple tables.Auto-increment will
SQL ServerThere are a lot of information about paging SQL, some use stored procedures, and some use cursors. I don't like using cursors. I think they are cost-effective and inefficient. Using Stored procedures is a good option, because stored
1. mysql remote connection commands can be used to remotely import and export data
Mysqldump -- default-character-set = gb2312-hsf-0000000.00-uroot-pxxxxxx mydatabase> d: \ data. SQL
Export the specified database to an external SQL file!
Restore
MySQL Remote Access command
Format: mysql-h host address-u user name-p User Password
Example:
Yanggang @ host :~ $ Mysql-h192.168.1.11-uroot-p123456
ERROR 2003 (HY000): Can't connect to MySQL server on '192. 168.1.11 '(192)
An error occurred!
In earlier versions of MySQL 3.22, the single table size of MySQL is 4 GB. At that time, the storage engine of MySQL was also the ISAM storage engine. However, when the MyISAM storage engine appears, that is, starting from MySQL 3.23, the maximum
On percona performance conference 2009, several Yahoo engineers brought a "Efficient Pagination Using MySQL" report, which has many highlights. This article is a further extension based on the original article.First, let's take a look at the basic
The following error occurs during mysql compilation and installation today:Checking for tgetent in-ltermcap... NoChecking for termcap functions library... Configure: error: No curses/termcap library foundIt indicates that the curses/termcap library
View the encoding: show variables like 'collation _ % '; show variables like 'character _ set _ %'; Modify: MySQL: Modify the default character set and convert the character set (MySQL 5.X) 1. modify the default character set of the MySQL database
1. Use the SHOW statement to find out the current database on the server: mysql> show databases; + ---------- + | Database | + ---------- + | mysql | test | + ---------- + 3 rows in set (0.00 sec) 2. CREATE a DATABASE abccs mysql> CREATE Database
Mysql was running well. I changed the root password once. It seems that it was not successful. At that time, I didn't care about it, and there was no problem with mysql. The next day, the error "access denied for user 'root' @ 'localhost' using
Fil_init mainly refers to the initialization file opening pointer hash table. All opened files are recorded in fil_system, And the buf_pool_init memory buffer pool Initialization is constructed for the hash table searched by name, corresponding to
The partition table function of MySQL is only supported since 5.1. If MySQL of Centos is 5.0, You Need To uninstall MySQL and install MySQL 5.1.The following are records of operations, errors, and solutions: 1. disable the current mysql
Mysql slow query configuration MYSQL slow query 1. What is the use of slow query? It records all SQL statements that have been executed longer than long_query_time, and helps you find slow SQL statements to optimize these SQL statements. 2. How to
We all know that MySQL is a small and medium-sized relational database management system. It is very practical and helpful for us to learn a lot of technologies. I installed SQL Server 2008 and Oracle 10g databases separately a few days ago, JDBC is
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