In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces what commonly used sentence commands are used to create MySQL, and the contents of the article are carefully selected and edited by the author, which are targeted and of great significance to everyone's reference. let's work with the author to understand what commonly used sentence commands are used to create MySQL.
MySQL common statement commands
Modify root password
SET PASSWORD FOR 'root'@'localhost' = PASSWORD (' newpass')
Create the database:
Create database cacti
Add new customers and grant permissions
Grant all on cacti.* to cacti@localhostidentified by "cacti"
Refresh permissions
Flush privileges
Import data
Mysql-uroot-p cacti use mysql
> update user set Update_priv ='Y 'whereuser =' root'
View temporary tables
Show variables like "tmp%"
Set the global temporary table size
Setglobal tmp_table_size=33554432
Modify MySQL remote connection permissions
Grant all privileges on *. * to 'root'@'%'identified by "123" with grant option
Show current user permissions
Show grants for root@'localhost'
Backup database
Mysqldump-uroot-p-database
Slow query log analysis
Open slow query
Log-slow-queries=/var/log/mysqld-slow.log
Long_query_time=2
/ / dbquery-slow
Query_time query time
Lock_time lock time
Number of rows returned by rows_send query
Number of rows for all queries in rows_examind
Timestamp timestamp
View the tablespace management type of the current database
Show variables like "innodb_file_per_table"
Innodb_file_per_table=1 to use exclusive tablespaces
Innodb_file_per_table=0 for using shared tablespaces
ON stands for independent tablespace management, and OFF stands for shared tablespace management
After reading the above about the common sentences and commands to create MySQL, many readers must have some understanding. If you need to get more industry knowledge and information, you can continue to follow our industry information column.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.