1. Install and download the Binary Package: because mysql is 5.1.48, select the corresponding package from the official website. http://q4m.kazuhooku.com/dist/old/ Decompress the Package. copy support-files/q4m-forward to mysql installation
Common mysql database operations (add users) 1. mysql user adding format: grant select on database. * to "username" @ "Login host" identified by "password"; www.2cto.com Example 1. Add a user test1 with the password abc so that he can log on to any
The Mysql database installation step is configure. Therefore, the installation method is Cmake, which is different from the configure version earlier than 5.5. The following are detailed installation steps: 1, extract the compressed file: tar-zxvf
MySQL Character Set and copy_and_convert about copy_and_convert when conducting a business stress test on MySQL, we found in the perf results that copy_and_convert is a cpu-consuming operation. This function refers to content conversion between
In MySQL, the string space in the query condition is assumed that there is a table in the current mysql database: sysuser has a field: The sysUseName field contains a record: here are the two SQL statements: www.2cto.com SELECT * from sysuser s
MySQL Master/Slave separation master database configuration 1,/etc/my. cnf master database configuration # generally, www.2cto.com server-id = 1 # Database binlog-do-db = search # Database replicate-ignore-db = that does not need to be copied
How to view, modify, delete, and create a stored procedure in the mysql tutorial
This article briefly introduces how to view, modify, delete, and create a mysql stored procedure. The following four examples are provided to demonstrate the
There are two main methods to process MYSQL transactions:1. Use begin, rollback, and commit to implementStart a transactionRollback transaction rollbackCommit transaction validation2. directly use set to change the automatic submission mode of the
Using MYSQL for database backup has a very regular database backup method, which has the same concept as other database servers, but have you ever thought about it, mySQL will have a simpler backup method using the file directory, and it will be
In mysql, paging optimization is a common problem. If we use limit for tens of thousands of data records, we can complete paging without any operation and the performance is good, however, for millions of data, we need to effectively optimize the
Several common mysql Functions/*************************************** **************1. Determine whether the string is returned from Chinese characters: 1-0-non-Chinese Characters**************************************** *************/Drop function
Myisam stores data in three files: MYD,. MYI,. FRM, and index files.Innodb stores data including. FRM storage table definition ,. ibd (exclusive tablespace ),. ibdata (shared tablespace ). innodb stores data in standalone and shared tablespaces
Environment MySQL 5.1 + command line toolProblem MySQL table field settings Default ValueSolution Copy codeThe Code is as follows:-- SQL:Create table test (I _a int NOT NULL DEFAULT 1,Ts_ B timestamp NOT NULL DEFAULT NOW (),C_c char (2) not null
Introduction Xtrabackup is a mysql database backup tool provided by percona. According to the official introduction, Xtrabackup is the only open-source tool in the world that can perform hot backup for innodb and xtradb databases. Features:(1) The
DATE_FORMA T (date, format) format the date or date and Time Value Based on the format string, and return the result string.You can use DATE_FORMAT () to format the DATE or DATETIME value to obtain the expected format. Format the date value based on
Connect to and disconnect the serverA
MySQLThe user name and a password may be required. If the server runs on a machine other than the login server, you must specify the Host Name:
shell> mysql -h host -u user -p
Enter
Copy codeThe Code is as follows:# Create a trigger. When a record is added to the order table, update the goods table.Delimiter $Create trigger trigger1After insert on 'order'FOR EACH ROWBEGINUPDATE goods SET num = num-new.much WHERE id = new.
There was a demand that had not been solved. After searching for half a day on google, none of the solutions provided could be used. Finally, the ghost was able to solve the problem.Suppose a table:Id f_id value1 22 2 B3 5 c4 9 c5 96 6 dId f_id
Before discussing how to start the MySQL server, let's take a look at the user identity to run the MySQL server. The server can be started manually or automatically. If you manually start it, the server is started as the user you log on to Unix
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