"If a worker wants to do his job well, he must first sharpen his tools." - Confucius, "The Analects of Confucius. Lu Linggong"
Front page > Programming > How to Establish Remote Access to a ClearDB MySQL Database on Heroku?

How to Establish Remote Access to a ClearDB MySQL Database on Heroku?

Published on 2024-11-17
Browse:321

How to Establish Remote Access to a ClearDB MySQL Database on Heroku?

Remote Access to ClearDB MySQL Database on Heroku

Querying a ClearDB MySQL database remotely can be achieved through tools like MySQL Query Browser. To establish the connection, you'll need the following information:

Acquiring Database Credentials and Connection Details:

  1. Navigate to the Heroku website and select "My Apps."
  2. Choose the app associated with the ClearDB database.
  3. Click on "Addons" and select "ClearDB MySQL Database."
  4. Select the desired database and navigate to the "Endpoint Information" tab.
  5. You will find the username and password needed to connect to the database.

Determining the Database URL:

  1. Open your command line and enter the following:

    heroku config --app 
  2. Replace with the actual name of your Heroku app.
  3. The output will include a line similar to:

    CLEARDB_DATABASE_URL: mysql://user:[email protected]/DATABASE?reconnect=true
  4. The database URL is the part that begins with "us-cdbr-east.cleardb.com".

Establishing the Remote Connection:

  1. Launch MySQL Query Browser.
  2. Enter the database URL, username, and password obtained in the previous steps.
  3. Click on the "Connect" button to establish a remote connection to your ClearDB database.
Latest tutorial More>

Disclaimer: All resources provided are partly from the Internet. If there is any infringement of your copyright or other rights and interests, please explain the detailed reasons and provide proof of copyright or rights and interests and then send it to the email: [email protected] We will handle it for you as soon as possible.

Copyright© 2022 湘ICP备2022001581号-3