Here are two methods for MySQL database backup/restore.
Method One:
Query ($sql); ///Make the generated temporary backup files together $outfile = Date ("y-m-d"). SQL "; if (File_exists ($dbdir. $outfile)) @unlink ($dbdir. $outfile); $FPR = fopen (
Looking for some information, and then I used the MySQL string processing of two functions concat () and left ()
1, "CONCAT (str1,str2,...)
Returns a string from the argument's link. Returns null if any argument is null. can have more than 2
Look at the manual found that the role of sql_calc_found_rows keyword in the query to meet the filter conditions after the total number of results (not limited by the Limit) specific use of the following, interested friends can learn under
MySQL's
Sometimes we need to copy a whole column of data from one field to another, or we need to copy the value of one of the fields from one table to a field in another table, this article lists some of the SQL statements, and the friends you need can
The basic syntax for a SELECT statement in MySQL is:
The following is a reference fragment:
SELECT [Straight_join] [Sql_small_result]
[Sql_big_result] [High_priority]
[distinct| distinctrow| ALL]
Select_list
[Into {outfile| DumpFile} '
Do MySQL 5.1 stored programs and functions work for replication?
Yes, the standard behavior performed in stored programs and functions is copied from the primary MySQL server to the from server.
Can the stored programs and functions created on the
When performing a rollback (rollback), if you receive the following message that 1 or more tables used in the transaction do not support transactions:
Warning: Some of the changed non-transactional tables cannot be rolled back.
These
Function
Mysql Spatial Extension
PostGIS
Spatial index
MyISAM only supports R-Tree indexing, InnoDB does not support
Gist Tree Index (variant of R-Tree)
Type of space supported
Only two-D data
MySQL master-slave replication principleMaster-Slave form
MySQL master-slave replication flexibility
One Master one from
Primary master replication
One master multiple reads from the---extended system, because reads are read
A) cannot display the Chinese solution:Reference: http://bbs3.chinaunix.net/thread-880131-1-1.html1:windows platform, because the Windows operating system defaults to using the gb2312 character, and when MySQL is installed,The default is that both
1. Before discussing this issue, first describe what is a "large data volume SQL file".Export the SQL file. Select the database-----Right-click to select Dump SQL file-----Select structure and data. Save the file Db_mras.sql file.2. Import the SQL
MySQL configuration file my.cnf A detailed explanation of Chinese, attached MySQL performance Optimization method sharing=================================================================================================MySQL parameter optimization
background: In recent years, open source databases have become popular. Due to its advantages of free use, simple configuration, good stability and excellent performance, open source database occupies a large market share in low-and middle-end
Currently encountering a data inconsistency, there are two tables, a project table, a project member table, the Project table has a field is the project work time, is the project member's working time summary. It's because of the logic, so change
When you use Sqoop to export data from hive to MySQL, you encounter an exception that is caused by the small max_allowed_packet settings of the exported database.By executing the command in the database:mysql> show variables like ‘max_%packet‘;+-----
1, database name and table name are strictly case-sensitive;2, the table alias is strictly case-sensitive;3, the column name and the alias of the column in all cases are ignored case;4, variable names are also strictly case-sensitive;MySQL is case
This article to you about the MySQL Chinese garbled problem how to solve (garbled problem perfect solution) of the relevant information, but also for you to collect some information about MySQL will appear in Chinese garbled reasons common points,
Easy to understand, directly on the example:SELECTCase-------------ifWhen sex= ' 1 ' Then ' Men '-------------sex= ' 1 ', then return value ' Male 'When sex= ' 2 ' Then ' Women '-------------sex= ' 2 ', then the return value ' female 'else 0---------
Mysql performance optimization solution (to) and mysql performance optimization solution
There are many MySQL performance optimization solutions on the Internet. However, compared with SQL server, mysql optimization is more troublesome and complex.
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