PHP connection MySQL test code:
$link=mysql_connect('localhost','root','123456'); if(!$link) echo "失败!"; else echo "成功!"; mysql_close(); ?>
Run code appears: Call to undefined function ' mysql_connect () ' ... Failed
Baidu found the result is
MySQL is a real multi-user, multi-threaded SQL database server. SQL (Structured Query language) is the most popular and standardized database language in the world. MySQL is implemented as a client/server architecture, consisting of a server daemon
Generally speaking, there are innodb, in most cases, InnoDB can meet our daily needs, so after MySQL 5.5, InnoDB as the default storage engine. That is, in addition to some features InnoDB cannot provide, we will be able to choose other engines.
1. Set up the character set when MySQL is installed
MySQL database is installed at the time. Select the language as UTF8 or GBK so that you can store Chinese in the database.
2. Setting the character set when creating a table
For example:
CREATE
System and Software versions:
CentOS Release 5.5 x86_64
Vsftpd-2.0.5-28.el5
Mysql-server-5.0.95-3.el5
PAM_MYSQL-0.7RC1.TAR.GZ Compilation Installation
Previously written vsftpd+tls+mysql solution, always unable to log into the FTP server
First, installation
To MySQL official online http://dev.mysql.com/downloads/mysql/, download MySQL can install the DMG version
For example:Mac OS X ver 10.7 (x86, 64-bit), DMG Archive
The downloaded files are: mysql-5.6.10-osx10.7-x86_64.dmg
1.
1. System environment and required software packages
Redhat Enterprise-5.8, vsftpd, MySQL, Pam-mysql-0.7rc1
2. General content of this article
①, VSFTPD installation
Introduction to ②, VSFTPD configuration files
Basic implementation and general
Must meet certain prerequisites to is able to restore a IBD tablespace:
1.The IBD file must to consistent backup with all insert buffer entries merged and have no uncommitted transaction s in order to is dependent of the shared 2.tablespace Ibdata.
1, create the path to save the backup file/mysqldata
#mkdir/mysqldata
2. Create/usr/sbin/bakmysql files
#vi/usr/sbin/bakmysql
Input
rq= ' Date +%y%m%d '
Tar Zcvf/mysqldata/mysql$rq.tar.gz/var/lib/mysql
or write
rq= ' Date +%y%m%d '
Http://dev.mysql.com/doc/refman/5.6/en/converting-tables-to-innodb.html
Identify all table information, display as MyISAM for MyISAM engine
SELECT table_name, ENGINE from INFORMATION_SCHEMA. TABLES where Table_schema = ' dbname ';
The second step
Today, when writing MySQL function, add comments to the content, found that the compilation error;
Find the manual to find, "--" note there is a small need to pay attention to: "--" and annotated content to add space between;
This thought is a
MySQL's performance starts with the view log. Low hardware configuration often leads to such problems, but in fact most of them are not here. Some "slow" SQL blocks the execution of other statements, and optimizing queries is the first step to be
How to combine fields from multiple tables in MySQL and then insert them into a new table, implemented in a single SQL statement. The scenario is: There are three tables A, B, and C, and now you need to insert the values from table B and table C to
Environment Introduction:
Use Yum to install a MySQL, because the version does not meet the requirements, the use of RPM uninstall, and the use of RPM installed a version of MySQL.
Error alert:
After MySQL installation, error log errors:
[ERROR]
"MySQL case" mysql-libs-5.1.73-3.el6_5.x86_64 conflicts with file from package Percona-server-server
If you encounter an error with the mysql-libs-5.1.73-3.el6_5.x86_64 conflicts with file from package Percona-server-server, there are two
1, the database can use only one index per query2, assuming that the data table T (A,B,C) ROWID is a physical locationrowID a b C(1) 1 1 1(2) 2 1 13(3) 2 2 14(4) 1 3 3(5) 2 3 12(6) 1 2 5(7) 2 3 9(8) 1 2 2(9) 1 3 6(10) 2 2 11(11) 2 2 8(12) 1 1 7(13) 2
This time install the database installed, do the next record.1. Download MySQL Source installation packageshell> wget http://dev.mysql.com/get/mysql57-community-release-el7-8.noarch.rpm2. Install MySQL sourceshell> Yum Localinstall mysql57-community-
MySQL optimization self-Summary, mysql Optimization
Through work and time learning, I have summarized the major aspects of MySQL optimization:
① Optimization on the storage layer (including storage engines, column types, and paradigm
Download and install mysql 5.7 or later, mysql or later
1. Download
1. mysql Website: https://downloads.mysql.com/archives/community/
2. decompress the downloaded package and decompress the package.
3. Place the folder in your favorite
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