CentOS6.5 installation configuration MySQL, the configuration method is as follows:
To install the MySQL database:# yum install-y mysql-server MySQL Mysql-deve
View Mysql-server version:# Rpm-qi Mysql-server
Initialize MySQL
Not a null constraint.The NOT NULL constraint can only be declared after the column name, cannot be declared with the constraint statement, and of course there is no way to declare the constraint name. The change field is NULL or NOT NULL only with
Summary: You can query the fields separated by commas and force the sorting of the results.First look at a table:
colid
Vyear
Area
cast
, 31,32,21,12
2014
1
15
, 32,
PHP uses the MySQL database, from the establishment connection to the display of the results.The complete code is as follows:PHP//Connect to MySQL$db=mysql_connect("localhost", "root", "root");if(!$db) { die(' Could not connect: '.Mysql_error());
In a production environment, sometimes we encounter the problem of removing 2 columns of data from the database and leaving a statement that solves this problem by using a unique federated indexCreate a test tableCREATE TABLE ' test03 ' (' ID ' INT (
Used to think that Mysql,innodb_buffer_pool_size=8g,mysql together will take up 8G of memory (think top can see the memory is used 8G), but recently carefully studied, it is not the case (perhaps their own Linux malloc memory allocation just knows a
Original address: http://blog.csdn.net/gamesofsailing/article/details/21465327After successfully installing PYTHON-MYSQL, start configuring the Django MySQL connection configurationOpen the setting.py file under the Django Project and change the
For MySQL databases , you must use the INNODB engine If you want to use transactions and row-level locks. If you want to use full-text indexing, you must use MyISAM. InnoDB is more practical, safer, more stable but less efficient than MyISAM, but
MySQL Monitoring management tool--innotop1.innotop InstallationReference official website: http://innotop.googlecode.com/svn/html/installing.html# wget http://innotop.googlecode.com/files/innotop-1.9.0.tar.gz# TAR-ZXVF Innotop-1.9.0.tar.gz# CD
Master-slave replication One, How master-slave replication works MySQL the process of implementing the entire replication between master and slave is done by 3 threads, of which two threads (SQL thread and IO thread)
Recently in the work, encountered the MySQL database connection time-out problem, my colleague to help solve a bit, see the original mysqlhelper inside there is no package related to the timeout method, added A, I recorded a bit here, I hope to like
Explain profilingIt is recommended to provide the following informationShow table status like ' audit ';Show create table audit;Show index from audit;Check table audit;Analyze table audit;Analyze does not check the table for problems, just
Mysql database operations groupby
During the IT interview, database-related questions are basically mandatory, and SQL statements are also an important knowledge point that is frequently investigated.
Next we will introduce an important operation
Inaccurate MySQL execution plan-Overview
The execution plan for the Mao MySQL optimizer is often inaccurate, but not optimal (cpu + io )???
Too many factors ::
The information of information_schema is regularly refreshed. In many cases, it is not
Create a MySQL database using Python to dynamically add fields and insert data
Application scenarios:
We need to design a database to save the keywords of each document in multiple documents. Assume that each document contains more than 1000
The new version of MySql5.6.20 cannot be logged on after installation
1. follow the prompts to install mysql2. run cmd to enter the mysql installation directory. Enter cd C in my installation directory C: \ Program Files \ MySQL Server 5.6 \ bin: \
Differences between the GroupBy sorting principles of MySQL and SQLLite
When we perform group by on the records of a table and do not explicitly use aggregate functions such as sum, min, and max, the group by sorting rules are as follows:
As we all
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