当前位置:网站首页>Get to know MySQL database
Get to know MySQL database
2022-06-24 03:11:00 【GUTSZ】
First time to know MYSQL database
1. What is? MYSQL?
MYSQL Is a relational database management system .
2. What is a database ?
A database is a collection of structured information and data , namely Database is used to store and query data .
3. Classification of database :
The database can be divided into Relational database and Non relational database .
(1) Relational database : A database that uses a relational model to organize data . A relational model is a two-dimensional table model , A relational database is a data organization composed of two-dimensional tables and their previous connections .
Presentation form of relational database :
Common relational databases are :
Oracle,MYSQL,SQL Server,DB2.
(2) Non relational database : No rules based on SQL Realization , Now it's more about NoSQL database .
Common non relational databases are :
a. Based on key value pair (key-value):memcached,redis
b. Based on document type : Such as mongodb
c. Based on column family : Such as hbase
d. Based on pattern : Such as neo4j
(3) The difference between relational database and non relational database :
4.MYSQL form :
MYSQL The composition of is divided into two parts :
Server side ( Service provider ), client ( Users of services ).
There is only one server , The client can have more than one .
We install on this machine MYSQL, It shows that we are both a server and a client , The embodiment of server-side service is :
The client is using MySQL Command Line Client as follows :
Use MySQL Command Line Client You can connect to the server , Enter the correct password to connect MYSQL( Server side ):

Ordinary console connection :
Besides using MySQL Command Line Client Outside the connection , We can also use normal console commands to connect , The connection command is :
mysql -h 127.0.0.1 -P 3306 -u root -p
among :
-h: host Abbreviation , Connect to the server ip Address ( If you connect this machine , It can be omitted );
-P: port Abbreviation of port number , by msql The port number on the server side , The default is 3306( If the machine is connected, you can omit );
-u: username Abbreviation , Indicates the user root Connect ;
-p: password Abbreviation , Indicates the password of the connection ;
Specify data when connecting :-D Database name
add to mysql environment variable :
The following error may occur during the first connection :
mysql Not an internal or external command , Nor are they runnable programs or batch files .
At this time, we need to mysql Add to the connection variable of the system :
1. find mysql Installation directory ;

2. take mysql Configure to the system environment .


Restart the console , Use the command to connect as shown in the following figure :
5.MYSQL Composition of server side :
mysql Important components of the server side are 4 individual :
database , surface , Field ( Column data ), data ( Row data ).
The database is equivalent to java The package name in , The table is equivalent to the class name , A field is equivalent to an attribute in a class , Data is equivalent to instantiating the object .
6.MYSQL In the program “ Location ”
7. summary :
(1)MYSQL Belongs to relational database , Software for storing and viewing data , Database is a concept ,MYSQL It belongs to concrete implementation .
(2) Database classification : Relational database 、 Non relational database 、MYSQL Belongs to relational database .
(3)MYSQL The composition is divided into client and server , The server side consists of the database 、 The data table consists of . A server can have multiple databases , One data can have multiple tables , There can be multiple data in a table .
边栏推荐
- 11111dasfada and I grew the problem hot hot I hot vasser shares
- Principle of efficient animation Implementation-A preliminary exploration of jetpack compose
- How to select a cloud game server? Which cloud game server recommends?
- What is the fortress machine? What role does the fortress machine play?
- Go program lifecycle
- [51nod] 2106 an odd number times
- RI Geng series: write a simple shell script, but it seems to have technical content
- Grpc: how to implement distributed log tracing?
- Double 11 will arrive soon. Is your website ready?
- Shopee Clickhouse cold and hot data separation storage architecture and Practice
猜你喜欢

2022-2028 global genome editing mutation detection kit industry survey and trend analysis report

2022-2028 global portable two-way radio equipment industry research and trend analysis report

2022-2028 global tungsten copper alloy industry research and trend analysis report
![[summary of interview questions] zj5](/img/d8/ece82f8b2479adb948ba706f6f5039.jpg)
[summary of interview questions] zj5

2022-2028 global third-party data platform industry research and trend analysis report

2022-2028 global aircraft front wheel steering system industry research and trend analysis report

2022-2028 global cancer biopsy instrument and kit industry research and trend analysis report
![[summary of interview questions] zj6 redis](/img/4b/eadf66ca8d834f049f3546d348fa32.jpg)
[summary of interview questions] zj6 redis

2022-2028 global pilot night vision goggle industry research and trend analysis report

2022-2028 global indoor pressure monitor and environmental monitor industry research and trend analysis report
随机推荐
Cloud desktop server resource planning, what are the advantages of cloud desktop
Gartner released the magic quadrant of enterprise low code platform in 2021. Low code integrated platform becomes a trend!
How to check the progress of trademark registration? Where can I find it?
What is the edge calculator force? What about the edge calculator?
Grp: how to gracefully shutdown a process?
Gigabyte was attacked by blackmail software, and the FBI banned the hacker organization Revil | global network security hotspot
How to access the server through the fortress machine? What's the use of the fortress machine?
Is AI face detection and face recognition a concept? What's the difference?
What does elastic public IP mean? The advantages of elastic public IP
What are the functions of Fortress machine equipment
Grand summary of boutique idea plug-ins! Worth collecting
JMeter script FAQs
What does cloud desktop mean? What are the characteristics of cloud desktop?
Permission maintenance topic: domain controller permission maintenance
Simple and beautiful weather code
Grpc: how do I start multiple ports?
Which domestic cloud desktop server is good? What are the security guarantees for cloud desktop servers?
[51nod] 3395 n-bit gray code
South Korea's national network is disconnected. Who launched the network "attack"?
2022-2028 global cell-based seafood industry research and trend analysis report