First, database acquaintance
Information: Click here to get information about this article!
DataBase is used for storing and managing data warehouse, its English word: DataBase, abbreviation: DB. A database is essentially a file system and is stored as files on a server’s computer. All relational databases can be managed using a common SQL statement, which is often referred to as the DataBase Management System DBMS.
The database has the following characteristics:
Can persist data, in fact, the database is a file system. A database can store and manage data. Use a unified way to operate the database -> SQL.Copy the code
Common databases are as follows:
Oracle: a large, fee-based database produced by Oracle corporation. MySQL: Open source free database, small database, has been acquired by Oracle. The mysql6.x version is also being charged. DB2: IBM database product, for a fee. Often used in banking systems. SQLServer: a medium-sized database that MicroSoft charges for. C#,.net and other languages. SQLite: a small embedded database used on mobile phones, such as Android. SyBase: has faded from the scene to provide a very professional data modeling tool PowerDesigner.Copy the code
Second, database ranking
Database ranking website: db-engines.com/en/ranking
Install MySQL
The installation process of MySQL is summarized as follows:
Run the following command to check whether MySQL is installed successfully:
MySQL > uninstall MySQL
Sometimes when MySQL is not installed successfully, you need to uninstall MySQL. However, if the uninstallation is not clean, then the probability of success in installing MySQL again is extremely low, or even at all. So you need to learn how to uninstall MySQL. Without further ado, the uninstall step begins. Step 1: Go to the MySQL installation directory and open the my.ini file:
Step 2: Use CTRL + F to search for the datadir. The result is the directory where the MySQL data is stored. If nothing else, the result is the same for everyone. When you find it, copy it, and you’ll use that directory later. My search results are as follows:
#Path to the database root
datadir="C:/ProgramData/MySQL/MySQL Server 5.5/Data/"
Copy the code
Step 3: win + r, then enter appwiz. CPL to open the Application Control panel, find MySQL, and uninstall it, as shown below:
Step 4: When we uninstall MySQL, it is not completely uninstalled. Use the path to the directory you found in step 2. We take part of the directory path: C:/ProgramData, and open the directory as shown below:
TIPS: After a successful uninstallation, you can install MySQL again.
So far, MySQL installation and uninstallation is done.
MySQL service startup and shutdown
Graphical interface: Open command line win + r, and then enter services. MSC to enter the service, as shown below:
Command line: open command line win + r, then enter net stop mysql to shut down mysql service, as shown in the following figure:
Ah, found not ah. Yeah, it’s a lack of access problem. Now let’s try running Net Stop mysql as an administrator. The diagram below:
MySQL > log in to MySQL
Command line: Open the command line win + r, and then enter CMD to enter the command line. Related operations are shown as follows:
Remember when we installed MySQL to set the password, there is a remote connection check, to connect to the remote database. Now let’s talk about it. For example: if I want to connect to MySQL in my cloud server, what do I do? Here’s how it works:
MySQL > select * from ‘MySQL’
1. MySQL installation directory
MySQL > install directory MySQL > install directory MySQL > install directory
2, MySQL data directory
So how does the client operate the database? The principle is as follows:
Tip: the client finds the computer through IP, finds the database server software through port, and finally operates the database and data tables through this software.
That’s it. This blog is over. Are you done?