I. MySQL Modify set initial password
After installing MySQL, log in to the GUI using the MySQL command:
650) this.width=650; "title=" 1.png "src=" Http://s2.51cto.com/wyfs02/M02/7C/F0/wKiom1bc6_XAJtq9AAAvoZI-b40759.png " alt= "Wkiom1bc6
There is a link on how to re-set password.Http://database.51cto.com/art/201010/229528.htmWords in short,Lines mysql> UPDATE mysql.user SET password=password (' Your_new_password ') WHERE user= ' root '; MySQL> FLUSH privileges;And about MySQL
Speaking of this, try to use mysqli_set_charset (mysqli: set_charset) instead of "set names". Of course, this content is also described in the PHP manual, but it does not explain why.Recently, several friends asked me this question. Why?When there
Copy codeThe Code is as follows: 'mark' set ('index', 'best', 'hot ')
There were few users and few people who knew about it. After a long time, I finally got a set of knowledge points.Looking at the above structure, MYSQL is not stupid. Will it
Recently, it has always been a headache to initialize data for the current project, and the auto-increment of database IDS is getting bigger and bigger, so we need to re-start auto-increment from 1: use the following method:
Method 1: If no data
When it comes to using Mysqli_set_charset (Mysqli:set_charset) instead of "Set NAMES", of course, this content is also described in the PHP manual, but it doesn't explain why.
Recently several friends have asked me this question, in the end
A set can contain up to 64 members whose value is an integer. (Set type base check MySQL data type set type) The binary of this integer indicates which members of the set's value are true. For example, there is a ' Status ' set
The code
The alternative is to use the timestamp type instead of the datetime type.Current_timestamp: When I update this record, this field in this record will not change.Current_timestamp on update current_timestamp: When I update this record, this field in
First, in Libmysql, the Mysql_opt_read_timeout settings item is provided, and the Libmysql provides an API for setting related settings items.
The code is as follows
Copy Code
Mysql_options: int stdcall Mysql_options
Go to MySQL to find help: such asEnter MySQL, authorize:All privileges: All permissionsOn *. *: All tables on all librariesTo that user @ that hostSet Password:#mysqladmin-u root password ' 123456 '; Change Password: # mysqladmin-uroot-p123456
1, the table's primary key, the foreign key must have the index;2, the data volume of more than 300 of the table should be indexed;3. Tables that are often connected to other tables should be indexed on the connection field;4. Fields that often
Recently re-installed the cloud host, but also install a variety of things, one of the need to set up MySQL permissionsFor learning convenience, I installed on my own cloud host is the Phpstudy integration environment, so to enter the MySQL console
Common phenomena:The MySQL master-slave server is often maintained in operations, but from the library we are only used for reading.General access is only authorized to read account, but sometimes maintenance work may not be a person doing, you can
1, change the table method. It may be that your account is not allowed to log on remotely, only on localhost. This time, as long as the computer on the localhost, log in to MySQL, change the "MySQL" Database in the "User" table "host", from
Windows edition MySQL sets the character set to UTF8 all the way my.ini file in MySQL installation directory [Client] node Default-character-set=utf8 (Increase) [MySQL] node Default-character-set=utf8 (modified) [mysqld] Node
MySQL remote access, that is, through IP access to the MySQL service, MySQL requirements for security is very strict and requires authorization.1. Local AccessSQL code
GRANT All privileges on * * to [e- Mail protected] identified by '
When installing MySQL, if you do not choose the encoding method, then the system will default to select Latin1 encoding, in the console window of MySQL input show variables like ' char% ' can view the database system's default encoding set, as
This article is a MySQL in the Set Type field of SQL Operation knowledge for a detailed analysis of the introduction, the need for friends under the reference
copy code code as follows:
The use of fewer people, understand less people, looking
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
Environment: navicatformysql8.2+ MySQL Sever 5.1
Problem: MySQL graphical settings unique key
Workaround: The graphical tool does not have this function. You can use SQL commands.
One: Modify the table, for example
ALTER TABLE tablename ADD
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.