Access mysql remote database from command line

后端 未结 17 1580
忘掉有多难
忘掉有多难 2020-11-28 01:41

I have a server with Rackspace. I want to access the database from my local machine command line.

I tried like:

mysql -u username -h my.application.com         


        
17条回答
  •  半阙折子戏
    2020-11-28 02:03

    For Mac, use the following command:

    mysql -u app -h hostaddress -P port -D dbname -p
    

    and then enter the password when prompted.

提交回复
热议问题