Connecting to MySQL Database over server

前端 未结 4 1862
北恋
北恋 2021-01-02 16:57

I\'m quite a beginner when it comes to working with networks and the like, so apologizes up front. A while back I set up a mySQL database locally on my machine, and have bu

4条回答
  •  青春惊慌失措
    2021-01-02 17:16

    You will use following commandline to connect -

    mysql -u -p -h
    

    For applications running on different machines trying to connect to your database, you only need to replace 'localhost' with your machine's hostname or ipaddress.

    In, general if you are able to ping your machine from a different system, your database can be connected to from that machine, just use whatever name you used for 'pinging' in place of localhost.

提交回复
热议问题