当前位置:网站首页>linux下新建Mysql数据库并导入sql文件
linux下新建Mysql数据库并导入sql文件
2022-06-30 15:33:00 【多汁多味】
0. 登录mysql
mysql -u root -p
1. 查看当前数据库
show databases; 
2. 新建mission数据库
create database mission; 
3. 查看是否新建成功
show databases; 
4. 切换到mission数据库
use mission;
5. 然后执行:其中/home/sql_file/mission.sql是我们要导入的对应的sql文件
source /home/sql_file/mission.sql 
6. 查看导入成功的表
show tables;

7. 查看表结构
desc mission;
边栏推荐
- catkin_ Make reports an error, transfers the location of the workspace, and uses other people's workspace files to cause compilation errors
- 1149 dangerous goods packaging (25 points)
- Teach you a learning method to quickly master knowledge
- Some reference routines for cache update
- Flask Sqlalchemy - automatically export the table model (flask sqlacodegen) & no single primary key problem ---orm (8)
- Review 2021, embrace change and live up to Shaohua
- Industry analysis | the future of real-time audio and video
- Is Domain Driven Design (DDD) reliable?
- 1134: Legal C identifier query
- Advanced functions of ES6 operation array map (), filter (), reduce()
猜你喜欢

Three types of technical debt that programmers often encounter: code, data, and architecture

Matlab construction operation example

Technology sharing | anyrtc service single port design

Npumcm selection question 3 and acmc2020a

The sound network has fully opened the real-time transmission network sd-rtn, which has been free of network wide accidents for seven years - this is FPA!

Matlab function for limit, definite integral, first-order derivative, second-order derivative (classic examples)

How should we understand the variability of architecture design?

Four solutions to cross domain problems

Tetris source code (color version)

Web technology sharing | whiteboard toolbar encapsulation of Web
随机推荐
[untitled]
Flask Sqlalchemy - automatically export the table model (flask sqlacodegen) & no single primary key problem ---orm (8)
Database connection to company database denied
HD mechanical principle · classic dynamic drawing of mechanical design
C. Registration system(map)
Bye civil engineering, hello CS, can you change the certificate to the Blue Bridge Cup
(Niuke) BFS
NPM install --global --save --save dev differences
String connector
N - Is There A Second Way Left? (minimum spanning tree, Kruskal)
1018 public bike Management (30 points)
Fundamentals of C language -- similarities and differences between arrays and pointers
4.7 type() function query data type
Preliminary study on AI noise reduction evaluation system of sound network
Basic literacy - four common software architectures
4.1 print function
Advanced functions of ES6 operation array map (), filter (), reduce()
Chapter 2 installation and use of vscode editor
Introduction to using 51 single chip microcomputer to control steering gear
1030 travel plan (30 points)