Lesson 2


Getting Started with MySQL

In this lesson you will connect to MySQL and explore a database then return results from a table

Commands used in this lesson include:

\sql – Switches the command shell over to SQL commands from JavaScript commands

\connect mysql://demo-user@localhost:3306 – Connects to the MySQL server on localhost port 3306

SHOW DATABASES; – Shows the databases on your server that you are connected to

USE demo; – Switches to the sakili database

SHOW TABLES; – Shows the tables in the sakili database

SELECT * FROM actors; – Returns all the rows and columns in the actors table