world_x database sample contains one JSON
collection and a set of three relational tables:
countryinfo: Information about countries in the world.
country: Minimal information about countries of the world.
city: Information about some of the cities in those countries.
countrylanguage: Languages spoken in each country.
To follow this quick-start guide you need a MySQL server with
X Plugin installed, the default in 8.0, and
MySQL Shell to use as the client. See
Installing MySQL Shell. Start MySQL before you
load the example
world_x database for this
To prepare the
world_x database sample,
follow these steps:
Extract the installation archive to a temporary location such as
/tmp/. Unpacking the archive results in a single file named
world_x.sqlfile to your database. You can either:
Start MySQL Shell in SQL mode and import the file by issuing:
mysqlsh -u root --sql --file /tmp/world_x-db/world_x.sql Enter password: ****
Set MySQL Shell to SQL mode while it is running and source the schema file while MySQL Shell is running by issuing:
\source /tmp/world_x-db/world_x.sql Switching to SQL mode... Commands end with ; \source /tmp/world_x-db/world_x.sql
/tmp/with the path to the
world_x.sqlfile on your system. Enter your password when prompted. A non-root account can be used as long as the account has privileges to create new databases.