1. Numeric typeAn integer type also has a property: Auto_increment. This property is used only for integer types when a unique identifier or sequential value needs to be generated. The auto_increment value typically starts at 1 and increases by 1
Mysql> CREATE TABLE Country (> country_id smallint unsigned not NULL auto_increment,>country varchar () NOT NULL,>last_update timestamp NOT NULL the default current_timestamp on update Current_timestamp,>primary Key (country_id)>) engine=innodb
1. Description of the errorError No. 2003Can ' t connect to MySQL Server on ' localhost ' (10061)2. Cause of Error Open Task Manager and close the Mysqld-nt.exe3, the solution of the methodMysqld-nt.exe is a MySQL daemon database service-related
The amount of data in a table is 1000W, so when you look at the hard disk space that the table occupies, the data itself is 300M and the index is 200MThis time, delete 500W data, this time the data itself 150M, and the index is still around 200MWhen
/*--name: MySQL version query paging stored procedure by peace 2013-8-14--input Parameters: @fields--The fields to be queried are separated by commas--Input parameters: @tables--the table to query-input parameters: @where --Query condition--input
Today to bring you the most simple MySQL master-slave copy of the tutorial, please continue to look down:MySQL master-slave replication principle:MySQL Replication is an asynchronous copy process, copied from one MySQL instace (we call Master) to
Order by sorting is the most commonly used feature, but sorting can sometimes encounter null NULL in the case of data, so the sorting will be messy, here in MySQL as an example, to record the problems I encountered and solve ideas.Problem:Page to
Introduction to MySQL Related conceptsMySQL is a relational database (relational databases Management System), this so-called "relational" can be understood as the concept of "table", a relational database consists of one or more tables .Basic
1. mysql 5.6 installation package download.
MySQL installation files are divided into two types, one in MSI format and one in ZIP format. If the MSI format can be directly clicked on the installation, according to the installation prompts
1, first install the Microsoft Visual C + + 2010 running environment, run the Vcredist_x86.exe file;2. Install MySQL database, run Mysql-installer-community-5.6.10.1.msi file3.4.5.6.7.8.9.10.11.12, the following are the default next to the
First login to MySQL:mysql-u root-p Note: The default root password is empty after MySQL is installed, not the system root password> set password for ' root ' @ ' localhost ' = password (' * * * * * '); --Modify the root user's local password> Grant
The mysql -uroot -p --default-character-set= -f following error is reported with the command line:ERROR 1839 (HY000) at line: @ @GLOBAL. Gtid_purged can only is set when @ @GLOBAL. Gtid_mode = on. source mode import resolved. $
String types are used to store string data, in addition to the string data that can be stored, as well as other data, compared to slices and sound binary data.
Type name
Description
Storage requirements
CHAR (M)
1. A convenient use of the while loop is to loop through the rows of data in a SQL query result.2, Mysqli_fetch_array (), this built-in PHP function gets a data row from the result of a database query, which can be paired with while repeatedly
For slow SQL Analysis steps: 1) Desc|explain SQL view execution plan, for type very slow, analysis whether to establish the corresponding field index 2) to exclude the method, the query extraction out, separate execution, positioning slow query is
MySQL: two categories
1. Name of each person whose score is greater than 80 in the following table?
Zhang San
Chinese
81
Zhang San
Mathematics
75
Li Si
Chinese
76
Li Si
Mathematics
90
Primary Key and foreign key of the database, primary key of the database
Primary Key and foreign key of the database
1. What are primary keys and Foreign keys:
A record in a relational database has several attributes. If one of the attribute groups
Understanding and operations of MySQL database transactions, mysql database transactions
A transaction is a series of operations performed as a single logical unit of work. These operations are submitted to the system as a whole, either executed or
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