本文介紹了從終端訪問 MAMP 的 MySQL的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!
問題描述
我想練習使用 SQL 而不是 phpMyAdmin.
I want to practice using SQL instead of phpMyAdmin.
如何從終端登錄 MAMP 的 MySQL?
How do I log into MAMP's MySQL from the terminal?
推薦答案
我假設您使用的 MAMP 版本會自行安裝在/Applications/MAMP 中.首先通過 MAMP 控制臺確保 Mysql 服務器已打開.然后從命令行像這樣連接:
I'm assuming the version of MAMP you're using installs itself in /Applications/MAMP. First make sure via the MAMP console that the Mysql server is on. Then connect like this from command line:
/Applications/MAMP/Library/bin/mysql -uUsername -pPassword
顯然替換用戶名和密碼.順便說一句,-u 和用戶名或 -p 和密碼之間沒有空格.
Obviously replace Username and Password. BTW, there is no space between -u and the Username or -p and the Password.
祝你好運以舊時尚的方式學習 Mysql!
Good Luck learning Mysql the old fashion way!
這篇關于從終端訪問 MAMP 的 MySQL的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!
【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!