1. Integral type
MySQL data type
Meaning (Signed)
tinyint (m)
1 byte range ( -128~127)
smallint (m)
2 byte range ( -32768~32767)
Mediumint (M)
3 byte range ( -8388608~83
master_server:192.168.159.10slave_server:192.168.159.111. Test Remote Account LoginMaster_server: #给backup用户授权mysql> Grant Replication Slave on * * to ' backup ' @ ' 192.168.159.11 ' identified by ' 123 '; #检查 authentication_string equivalent to
Company new platform on-line, the old database has some original user data need to migrate to the new platform, specially developed this script to ensure data integrity, and efficiency #!/bin/bash# #到出旧数据库中需要的表echo "Please prepare 3 files in the
bigint Integer data (all numbers) from -2^63 (-9223372036854775808) to 2^63-1 (9223372036854775807). The storage size is 8 bytes.Int Integer data (all numbers) from -2^31 (-2,147,483,648) to 2^31-1 (2,147,483,647). The storage size is 4 bytes. The
00–undo LogUndo log is for the atomicity of transactions, in the MySQL database InnoDB storage engine, also with the undo log to achieve multi-version concurrency control (abbreviation: MVCC).-Atomicity of the transaction (atomicity)All operations
1. Root user login to MySQL databasecode example:/usr/local/mysql/bin/mysql-u root-p (enter the password into MySQL)2. Go to MySQL and enter:code example:Use MySQL;3. View the user tablecode example:SELECT Host,user from User;Indicates the host name,
Empty all content from a MySQL table
Delete from table name ;
TRUNCATE table name ;
The DELETE statement without the Where parameter removes everything from the MySQL table, and you can also empty all the contents of the MySQL table
Source: a stewed egg
Links: http://www.cnblogs.com/lyroge/p/3837886.html
background:One of their own site, because the single-table data record up to 1 million, resulting in slow data access, the background of Google Analytics
First, open the Binlog. Show variables like ' Log_bin ';650) this.width=650; "Src=" Http://s1.51cto.com/wyfs02/M00/83/A8/wKiom1d51KaAqKsqAAAZuhGGanc245.png-wh_500x0-wm_3 -wmp_4-s_824524314.png "title=" FVI${YCWRF (fi4anyg$ky_u.png "alt="
Linux under MySQL Insert update delete transaction user management1.INSERT INSERT statement Format:INSERT into Tb_name (Field 1, Field 2, ...) Values (value 1, value 2, ...) [, (value 1, value 2, ...),...];INSERT into table name SET field 1= value 1,
Environment: Two Ubuntu 12.04.5 virtual machinesMySQL-server-5.5Master (192.168.240.130) Slave (192.168.240.129)(1See if binary logs are turned on show variables like' Log_bin ';(2) Login master, open a database account grant REPLICATION SLAVE on* *
http://my.oschina.net/zxu/blog/185977In MySQL master-slave replication, it is necessary to promote the repository (actually from the library) to the primary library, which needs to be removed from the library role, which can be performed by:Stop
Download the MySQL source package and unzip it.wget http://dev.mysql.com/get/Downloads/MySQL-5.1/mysql-5.1.73.tar.gzTAR-ZXVF mysql-5.1.73CD mysql-5.1.73
Create user, Basedir DataDirUseradd-s/sbin/nologin
Mycat1.5 ~ A bug in 1.6, mycat1.5 ~ 1.6bug
The following statement runs normally in a single mysql database:
SELECT * FROM device WHERE devicetype = 'ams. Monitoring. XlCloud. qkl8154.xlclouddevic'
However, if this function is enabled in
SQL-mysql common operation statements (Entry level), sqlmysql
1. Enter the database:
Mysql-u root-p
Mysql-h localhost-u root-p database_name
2. List Databases
Show databases;
3. Select a database:
Use databases_name;
4. List data tables:
Show tables;
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