CP363 : Connecting to MySQL - HeidiSQL

Overview

HeidiSQL is a DBMS that is compatible with MySQL, and is installed in Laurier's public labs. (You may use a front end other than HeidiSQL if you like, but we provide no documentation or help for other packages.) HeidiSQL can be used as a standard Windows program or used in portable mode installed on a USB stick or other device.

Starting HeidiSQL brings up the Session Manager. This window provides instructions on how to define a session. Press , give the session a name, and fill in the items in the Session tab. This sample window shows the data to provide to connect to the DCRIS database:

sessionData (20K)

The DCRIS database settings are:

You have also been given a personal database schema on the Department's student server, hopper.wlu.ca Your hopper database settings are:

This should be sufficient to connect from on-campus lab PCs.

Press to connect to the database.


Wireless Connections

If you wish to use a wireless connection, Laurier allows ssh (Secure Shell) connections to hopper, but not to any other ports. (The ssh port is 22, the database port is 3306). SSH Tunnelling allows the ssh port to act as a proxy for any other port on hopper. HeidiSQL allows you to set up tunnelling. First, from the Session Manager Settings tab choose a Network Type of MariaDB or MySQL (SSH tunnel), then fill in the information on the SSH tunnel tab:

sessionData (20K)

plink.exe is a program required by HeidiSQL to create the ssh connection. You must download and install it on your laptop for the tunnelling to work.

The Username and Password fields are your hopper/Laurier login and password, not your hopper database password mentioned above.


Using HeidiSQL

Note: Laurier does not allow off-campus database connections to either bohr or hopper.

Once connected to a database, you may examine the database contents and structure. The three most important top-level tabs are the Table tab:

tableTab (72K)

the Data tab:

dataTab (41K)

and the Query tab:

queryTab (34K)

The purpose of this document is to get you started using HeidiSQL. Using HeidiSQL further is fairly straightforward. When in doubt, HeidiSQL provides a comprehensive help and tutorial document at Basic help on using HeidiSQL.