Exercise 4.01 – working with simple queries
In this exercise, you will be using the world
database. As a developer, you will often need to use languages in your applications. You can download the world database here: https://downloads.mysql.com/docs/world-db.zip/. You are told that languages are stored in the countrylanguage
table of the database, but you are not aware whether the language is stored as a name or in the form of code. You will first inspect the table definition and then get a sample of the table. You need to make sure that you have the world database available; refer to the Loading data from a SQL file section in Chapter 11, MS Excel VBA and MySQL if you have questions. Follow these steps to complete this exercise:
- Connect to MySQL with the CLI and the appropriate user.
- Select the world database to be used:
USE world;
The current database will be changed to the world
database, as you can see in the following figure: