First we create a comma-delimited string. CREATE TABLE Test (id int (6) NOT NULL auto_increment,primary KEY (ID), pname varchar (a) not null,pnum varchar (a) NOT null) ; Then insert the test data with a comma-delimited INSERT into Test (pname,pnum)
This article is based on CentOS 64-bit 1. Download MySQL first (mysql-5.6.27-linux-glibc2.5-x86_64.tar.gz) Download http://dev.mysql.com/downloads/from official website Select the appropriate Linux version 2. Copy the
Five statistical functions (used alone, with little meaning, often used in combination with grouped group by)Max Max select Max (shop_price) from goods;Min min Select min (shop_price) from goods;Sum sum select SUM (shop_price) from goods;AVG
Left and right connectionsFull multiplication method (very low efficiency)Mysql> select * from Test10;+------+-------+| ID | sname |+------+-------+| 1 | Cloud || 2 | Moon || 3 | Star |+------+-------+3 Rows in Set (0.00 sec)Mysql> select * from
To create a user:' username '@'host'password';Description: username– You will create the user name, host– specifies which host on which the user can log on, if localhost is available to local users, you can use the wildcard% if you want the user to
One, MySQL cache:1. The cache includes:(1), cache query plan to avoid two lexical parsing, optimization, execution.(2), the cached MySQL query statement returns the full result, when hit, MySQL will understand the return results, eliminating the
MysqlIncremental BackupBinlog is an incremental backup, confirming that the next binlog is turned on:#grep "Log-bin"/etc/my.cnfmethod of incremental recoverymost basic sub-recovery#mysqlbinlog mysql-bin.000001 >bin.sql#mysql-uroot-p ' abc-123 '
See which libraries > show databases are available;View the table > use DB for a library; Show tables;View table fields > Desc TB;View Build Statement > Show CREATE TABLE TB;Which user is currently > select User ();View current Library > select
In Linux, if we want to use a relational database, basically is MySQL, and the previous version of 7 CentOSThe system is the default integrated with MySQL. However, for the current CENTOS7 system, MySQL database is not supported, it defaultsInternal
Indexing is the key to fast searching. MySQL indexing is important for the efficient operation of MySQL. Here are a few common types of MySQL indexes.In a database table, indexing a field can greatly improve query speed. Suppose we create a mytable
about MySQLA database is a container for storing organized data.The database management system DBMS is the software that operates the database.A table is a structured file that can be used to store specific types of data. Table names in the same
Phenomenon: When the data inserted into the database is in Chinese, the following error is reportedThe reason is: the system default encoding of the computer is GBK, and the MySQL client provides encoding method is UTF8, two encoding inconsistency
MySQL new features-mysql_config_editor source code analysisMysql has launched the encryption tool mysql_config_editor since mysql5.6. Previously, we put the account and password in plain text into my. cnf, so that you can log on to the database
Data File suffix
Today, we saw 99 tablespaces in the production system. We decided to add data files to the tablespaces. No problem.
At night, you get cold sweat. Production system RAC. data files are stored in shared storage. The path is correct,
Basic tutorial on statistical query of several data types in MySQL,
Average statisticsThe select avg () FROM syntax is used to calculate the average statistics FROM a data table.Syntax:
SELECT AVG(column) FROM tb_name
This SQL syntax is used to
Share some of MySQL's functional and practical Linux shell scripts,
Memcached Startup Script
# vim /etc/init.d/memcached
#!/bin/bash#=======================================================================================# chkconfig: - 80 12#
Add and query MySQL Data Using a PHP script,
MySQL Insert Into add dataINSERTThe insert into syntax is used to add data records to a data table.Syntax:
INSERT INTO tb_name VALUES (value1, value2,...)
This syntax inserts data records into all fields
[Original] mysql Error Buffer Stack
What is an error buffer stack? For example, execute the following statement:
mysql>INSERTINTOt_datetimeVALUES(2,'4','5');ERROR1292(22007):Incorrectdatetimevalue:'4'forcolumn'log_time'atrow1
Where is the error
Use MySQL logs to view execution statements and update logs in real time,
View the statements executed by MySQLYou can view the SQL statements executed by MySQL in real time, similar to the event probe in mssql. Set the my. ini file to open the file
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