当前位置:网站首页>MySql的安装配置超详细教程与简单的建库建表方法
MySql的安装配置超详细教程与简单的建库建表方法
2022-07-25 15:10:00 【微凉秋意】
作者简介:C/C++领域新星创作者,为C++和java奋斗中
个人主页:微凉秋意的主页
系列专栏:MySql一点通
推荐一款模拟面试、刷题神器注册免费刷题
前言
数据库是一名程序员必会的技术,那我就来分享一下我的
MySql语言学习之路。这篇博客将分享MySql从零到一的安装、配置环境变量、建库建表等,后续的增删改查、视图、索引、事务、JDBC技术也会陆续在这个专栏更新,感兴趣的朋友可以免费订阅哦~
一、MySql的安装与环境配置
MySql的下载安装
- 官网链接,点击即可跳转 MySQL下载
- 跳转链接后点图示的“中文”

- 点击
GPL
继续按照图示点击
点击download
- 下载完成后是这个样式,双击开始下载

- 下载的时候一定要记住自己设置的密码,其他东西直接点
next即可
配置环境变量
先检验能否登入数据库
- 打开MySql所在的
bin目录,输入cmd进入黑窗口
- 输入
mysql -u root -p,随后输入你安装时设置的密码,和图片一致说明成功
配置环境变量
- 复制MySql的
bin路径 - 找到系统的环境变量,新建后输入复制的bin路径并确定即可

二、建立数据库的工具
- 可以在CSDN的资源里搜索并下载
navicat12018_premium_cs_x64,私信博主也可以 - 下载完成后测试连接数据库

- 如果连接失败,参考下面的解决方案

三、数据库的建立和表的建立
数据库的建立
- 首先连接MySql数据库,界面如下:

- 点击新建查询并输入
create database if not exists 数据库名,效果如下:
表的建立
- 再次新建查询,写入代码:
create table if not exists myTable(
name varchar(20) primary key,
age int not null
)
这里只是简单演示一下表的建立,后续文章会详细介绍表的约束等知识点
- 效果如下:

结语
这么干货的教程,还不收藏起来去搭建MySQL环境!如果缺少Navicat工具可以私信博主获得,安装过程中有问题也可以找我解答,最后求一个三连支持不过分吧~
边栏推荐
猜你喜欢

Bridge NF call ip6tables is an unknown key exception handling

Sudo rosdep init error ROS installation problem solution

树莓派入门:树莓派的初始设置

oracle_12505错误解决方法

39 simple version of millet sidebar exercise

用OpenPose进行单个或多个人体姿态估计

Leo-sam: tightly coupled laser inertial odometer with smoothing and mapping

Leetcode combination sum + pruning

Nacos2.1.0 cluster construction

Pl/sql creates and executes ORALCE stored procedures and returns the result set
随机推荐
TypeScript学习2——接口
【微信小程序】小程序宿主环境详解
打开虚拟机时出现VMware Workstation 未能启动 VMware Authorization Service
Spark 判断DF为空
SQL Server forcibly disconnects
args参数解析
[Android] recyclerview caching mechanism, is it really difficult to understand? What level of cache is it?
Detailed explanation of lio-sam operation process and code
Sudo rosdep init error ROS installation problem solution
27 选择器的分类
[comprehensive pen test] difficulty 4/5, classic application of line segment tree for character processing
给VS2010自动设置模板,加头注释
String type time comparison method with error string.compareto
MFC 线程AfxBeginThread基本用法,传多个参数
RedisCluster搭建和扩容
用setTimeout模拟setInterval定时器
[C题目]力扣206. 反转链表
Rediscluster setup and capacity expansion
sql to linq 之存储过程偏
树莓派入门:树莓派的初始设置