MySQL: a first look at a
database server + some
basic SQL queries
A HANDS-ON, PRACTICAL SESSION (YAY, FINALLY, FANTASTIC EH?!)
,MySQL? What is it?
An open-source relational database management system (RDBMS)
Correctly pronounced “My S-Q-L”
Originally created by Swedish company MySQL AB in 1995
MySQL AB later purchased by Sun Microsystems in 2008 (creators of Java, Solaris operating
system and SPARC workstations etc. but did not own a DBMS product)
Sun Microsystems purchased by Oracle in 2010 (who did own their own DBMS product already),
resulting in MySQL forking to create permanently free MariaDB variant by the original
developer, which is mostly compatible with MySQL interfaces and tools
In many cases MariaDB can be a “drop in” replacement for MySQL
, What do we need to run to try it?
First, we need a MySQL (or MariaDB) database server
The network PCs have MySQL server installed on it but it’s not running automatically as a Windows service (as it normally would be on other PCs)
We need to run a batch file (script) to launch it each time ourselves, installed on lab machines already (search on start menu for Start-MySQL.bat)
Then run Start-MySQL.bat by clicking on it
It should take a few seconds to start running but eventually a blank window with the title “MySQL” should appear
If it appears briefly and then disappears straight away, there’s an error. Looking in M:\MySQL\Data\ for a .err error file and examining the contents gives
clues!
DO NOT close the window manually or log off while it’s running - Use Stop-MySQL.bat to shutdown server when necessary!
NB. You DO NOT need these batch files when using MySQL on your own computer (it normally runs as a Windows NT Service automatically) and they
WILL NOT work on your own computer
Second, we need a MySQL database client so we can:
Communicate with the server
Create/maintain databases
Run queries
Etc.
MySQL Workbench is already installed for this
Therefore, this is a client/server system. The server does all the work, the client displays the results and provides the User Interface
database server + some
basic SQL queries
A HANDS-ON, PRACTICAL SESSION (YAY, FINALLY, FANTASTIC EH?!)
,MySQL? What is it?
An open-source relational database management system (RDBMS)
Correctly pronounced “My S-Q-L”
Originally created by Swedish company MySQL AB in 1995
MySQL AB later purchased by Sun Microsystems in 2008 (creators of Java, Solaris operating
system and SPARC workstations etc. but did not own a DBMS product)
Sun Microsystems purchased by Oracle in 2010 (who did own their own DBMS product already),
resulting in MySQL forking to create permanently free MariaDB variant by the original
developer, which is mostly compatible with MySQL interfaces and tools
In many cases MariaDB can be a “drop in” replacement for MySQL
, What do we need to run to try it?
First, we need a MySQL (or MariaDB) database server
The network PCs have MySQL server installed on it but it’s not running automatically as a Windows service (as it normally would be on other PCs)
We need to run a batch file (script) to launch it each time ourselves, installed on lab machines already (search on start menu for Start-MySQL.bat)
Then run Start-MySQL.bat by clicking on it
It should take a few seconds to start running but eventually a blank window with the title “MySQL” should appear
If it appears briefly and then disappears straight away, there’s an error. Looking in M:\MySQL\Data\ for a .err error file and examining the contents gives
clues!
DO NOT close the window manually or log off while it’s running - Use Stop-MySQL.bat to shutdown server when necessary!
NB. You DO NOT need these batch files when using MySQL on your own computer (it normally runs as a Windows NT Service automatically) and they
WILL NOT work on your own computer
Second, we need a MySQL database client so we can:
Communicate with the server
Create/maintain databases
Run queries
Etc.
MySQL Workbench is already installed for this
Therefore, this is a client/server system. The server does all the work, the client displays the results and provides the User Interface