If you manage a MySQL database server, you may or may not have the skills to do so from the command line. It takes quite a lot of skill and patience to tackle that task from the console. For those who don’t have the time to learn the MySQL console or who just prefer a good GUI tool for the task, there are a number of tools available for the management of a MySQL database. One such tool is Toad for MySQL.

Toad is a free developer tool that helps you:

  • Quickly create and execute queries
  • Automate database object management
  • Develop SQL code more efficiently
  • Compare, extract, and search for objects
  • Manage projects
  • Import/export data
  • Administer databases
  • Increase productivity
  • Access an active user community

Toad for MySQL’s features include:

  • Version Control Integration: Check in and check out code
  • Macro Record and Playback: Record and play back keyboard commands
  • Database Browser: Reorganize and manage objects and object types
  • Code Snippet Editor: Create and alter code snippets for expand-and-collapse code blocks
  • Security Manager: Permit or restrict user access to specific features
  • SQL Editor: Create, execute, modify, and save queries; view and edit data; process DDL commands.
  • Fast, Multi-Tabbed Schema Browser: Display and manage database objects graphically
  • DB Extract, Compare-and-Search Utility: Compare two MySQL databases, view the differences, and create the script to update the target
  • Import/Export Utility: Transfer data across MySQL databases

Installing Toad

Since Toad is a Windows tool, the installation is just a matter of downloading the latest stable (click the Download button here and fill out the necessary information) and then following these steps:

  1. Unzip the downloaded file.
  2. Change into the newly created file.
  3. Double-click the ToadforMySQL_Freeware installation file.
  4. Walk through the installation wizard.

Once installed, you can start the program from Start | Quest Software | Toad For MySQL | Toad For MySQL. When the main window opens (Figure A), you’re ready to begin.
Figure A

The Toad for MySQL main window. (Click the image to enlarge.)

Setting up connections

First, you need to create connections. Whether you are connecting to a local MySQL server or a remote server, it’s quite simple.

  1. Go to File | New | Connection.
  2. In the Create New Connection dialog (Figure B), enter the necessary information for the connection.
  3. Click Save.

Figure B

You can label a connection as Development, Production, Test, or create your own labels. (Click the image to enlarge.)

From the Connection Type drop-down shown in Figure B, you can select from these types of connections:

  • TCP
  • Named Pipe
  • Memory
  • SSL
  • SSH
  • HTTP Proxy
  • HTTP Tunnel

If you are connecting to a remote server, you have to make sure the machine Toad is installed on has permission to access the remote MySQL database server.

After you create the new connection, it will be listed in the Connection Manager. Double-click the new connection, enter the password for the connection, and click Connect. You should be presented with the Information Schema browser on that server (Figure C).
Figure C

Select the different Schema on this server from the Information Schema drop-down immediately below the tabs in the middle pane. (Click the image to enlarge.)

Creating a database (schema)

  1. Go to File | New | Database and give the database a name.
  2. Click OK.

Now if you click the Information Schema drop-down, you should see that new database listed.

Creating a table on a database

  1. Select the new database from the Schema drop-down.
  2. Click the Create A Table button in the Tables tab for the database.
  3. In the General tab, give the table a name.
  4. In the General tab, select the database engine.
  5. In the General tab, configure any other options necessary.
  6. In the Columns tab, select the data type.
  7. In the Columns tab, configure the length.
  8. In the Columns tab, if more columns are needed, click the Add button.
  9. Click OK.

You should see your table in the right pane (Figure D).
Figure D

Click the image to enlarge.

We created a fairly basic table. There is quite a lot more that Toad for MySQL can handle, but now you should have a grasp on getting it up and running and using it to handle some simple tasks. If you’re a DBA, you most likely can take it from here.