Home > Database > Mysql Tutorial > Mac下操作mysql_MySQL

Mac下操作mysql_MySQL

WBOY
Release: 2016-06-01 13:36:50
Original
961 people have browsed it

bitsCN.com


Mac下操作mysql

 

 1、先到mysql官网上下载dmg格式安装包,进行安装。

 2、安装完后,命别名:

alias mysql=/usr/local/mysql/bin/mysql

aliasmysqladmin=/usr/local/mysql/bin/mysqladmin

 

给root创建密码:

/usr/local/mysql/bin/mysqladmin -u root password root

 

使用终端来打开或关闭mysql:

sudo /Library/StartupItems/MySQLCOM/MYSQLCOM [start | stop | restart]

进入数据库:

mysql -u root -p

随后输入密码:root

bitsCN.com
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template