The Linux installation MySQL service is divided into two installation methods:
① source installation, the advantage is that the installation package is relatively small, only more than 10 m, the disadvantage is that the installation relies on more
For the MySQL table based on the operation, the specific contents are as follows
1. Create a table:To create a table's syntax form:
CREATE TABLE table_name (
property name data type,
property name data type,
...
) Property name Data
First, FOREIGN KEY constraints
MySQL uses foreign KEY constraints to guarantee the integrity and accuracy of data between tables.
Use conditions for foreign keys:
1. Two tables must be INNODB tables, MyISAM table temporarily does not support
Have nothing to do, find a practice to write at work, the contact topic is for SQL Server 2000, the following MySQL
One word explanation (2 points/a) 34 points
Data data Database RDBMS relational database management System grant authorization
REVOKE
Searching the web for half a day, the easiest way is to create a database in the new database that is the same as the original name, and then copy the. frm file into the OK.
However, sometimes this is not the case, the query will appear so-and-so
There are 2 waysOne, can modify My.ini configuration parameters (Linux below is MY.CNF);[Quote] [Client]port=3306Default-character-set=utf8Host=localhostUser=rootPassword=1[/quote]The exact other parameters can be modified hereSecond, can modify
1, select the most applicable field properties
MySQL can support a large amount of data access, but generally speaking, the smaller the table in the database, the faster the query executed on it. Therefore, in order to achieve better performance
Error starting MySQL, view the next status, found that the MySQL is not running,but lock exists:
a netizen said May and log file, so the log file to remove, and then restart MySQL finally OK
Looked for the information, basically is to say:
After G, the solution is as follows:
/var/lib/mysql directory, delete ibdata1, Ib_logfile1, IB_LOGFILE0, and then restart MySQL to rebuild the files above:
Mysqladmin-uroot-p shutdown
sudo mysqld_safe &
Get!
The following are other articles on the
Copy Code code as follows:
?
$DBH = @mysql_connect ("localhost:3306", "root", "000000");
/* Define variable DBH, the mysql_connect () function means to connect to the MySQL database, "@" means to block the error * *
if (! $dbh) {die ("
You can use the following statement
Query_cache_size = 268435456
Query_cache_type = 1
Query_cache_limit = 1048576
Deposit to [mysqld] of/etc/my.cnf file
Then restart the MySQL database
Service mysqld Restart
will start the MySQL caching mechanism
MySQL's SQL is used to adjust the main use of EXPLAIN, but this does not know the details of the Ram (Memory)/cpu and so on.
After MySQL 5.0.37 is available to support MySQL Query Profiler, you can find out how much time this SQL will perform, see
Recently, I took time to change into syntaxhighlighter. Because the start tag for the Coolcode plugin is
or [Coolcode] like this, and Syntaxhighlighter is
[Code lang= "PHP"]
such as (or other). So we can only find ways to transform the old format
First set up the query page:
Copy Code code as follows:
Add Records
Employee Name:
PC Name:
As you can recall, in the previous topic, we have already described how the PHP page transfer
Grammar:
Group_concat ([DISTINCT] expr [, expr ...] [ORDER BY {Unsigned_integer | col_name | expr}[asc | DESC] [, col_name ...]] [SEPARATOR Str_val])
Here is a demonstration of this function, first set up a student to choose the timetable
How MySQL takes random data out of a tablePreviously discussed this problem in the group, the comparison is interesting. MySQL's syntax is really fun. They all want to use PHP to achieve random, but take out more than two times as if the query.
The basic syntax for the CREATE TABLE statement in MySQL is:
Create [temporary] TABLE [IF not EXISTS] tbl_name [(create_definition,...)]
[Table_options] [Select_statement]
Temporary: This keyword indicates that the new table created with the CREATE
How to get better full-text search results in MySQL
Author: Techrepublic.com.com
2006-04-03 11:14:53
Many Internet applications provide full-text search capabilities, and users can use a word or phrase as a query item to locate matching records.
MySQL supports a large number of column types, which can be grouped into 3 categories: numeric types, date and time types, and string (character) types. This section first gives an overview of the available types, summarizes the storage requirements
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