# MySQL问题汇总
# 介绍
[TOC]
环境:CentOS7版本
问题:CentOS7安装Mysql时没有mysql-server可用包
解决方法:
yum -y install wget
#下载mysql的repo源
wget http://repo.mysql.com/mysql-community-release-el7-5.noarch.rpm
#安装mysql-community-release-el7-5.noarch.rpm包
rpm -ivh mysql-community-release-el7-5.noarch.rpm
#安装mysql
yum install mysql-server
#查看mysql 服务状态
systemctl status mysql
#启动mysql
systemctl start mysql
1
2
3
4
5
6
7
8
9
10
11
2
3
4
5
6
7
8
9
10
11
参考链接Linux下安装Mysql时没有mysql-server可用包的解决 (opens new window)
//获取数据中指定表表名
SELECT table_name FROM INFORMATION_SCHEMA.TABLES where TABLE_NAME = 'test'
1
//获取数据中指定表列名
SELECT table_name FROM INFORMATION_SCHEMA.COLUMNS where TABLE_NAME = 'test'
1
← MySQL大小写敏感配置 SQL练习 →