Asked 4 years, 1 month ago

Viewed 16k times

How would I go about installing the Sakila database onto my Mac?

Importing Data and Schema to MySQL Workbench

I've used the comment by user dr01 in this post, but I'm not sure if I'm ready to use it or not. The Sakila file I downloaded has 3 files (sakila-data.sql, sakila-schema.sql,sakila.mwb) but I only used the schema file while importing it into Workbench. Thanks.

asked Aug 9, 2018 at 11:19

Pretty simple: the Sakila DB is so small you can just run the 2 SQL files in Workbench:

  • Download the sakila dump from
  • Open a connection to your server in MySQL Workbench, where you want to load Sakila.
  • In the SQL editor toolbar there's a button to load a file. Click that and select sakila-schema.sql.
  • Once loaded you just execute the full editor content. This is for the DB structure.
  • Now load the content by opening the sakila-data.sql script. Again, execute the entire editor.

Now refresh the schema tree by clicking on the small refresh icon

and you should see the Sakila schema in the tree. That's it.

answered Aug 10, 2018 at 6:56

Mike LischkeMike Lischke

44.7k15 gold badges105 silver badges162 bronze badges


Execute the installer again, choose -> Documentation/Samples and Examples and your done

answered Aug 24, 2019 at 14:47

Just like SQL Server, I do consult with MySQL, PostgreSQL, and MariaDB. One of the most popular questions, I often receive during my consulting engagement is that where can one download the sample database for various databases. While we should always test all of our queries with the real workload as well as the real database. However, whenever we are exploring the new feature, it is a good idea that we work with the sample database and build our scripts which we can eventually apply to the production database.

MySQL Sample Database

Just like SQL Server Sample Databases, MySQL also has sample databases and they are listed here: Example Databases. I am personally a very big fan of MySQL database sakila and whenever I am presenting a consulting session or training on performance Tuning, I use this database to demonstrate the capability of the MySQL.

Here is the list of the sample databases and their installation process.

  • Sakila Database (documentation| download)
  • World Database (documentation | download)
  • Employee Data (documentation | download)

Out of all the three databases, Sakila database is my favorite database. The Sakila database was initially developed by Mike Hillyer, a former member of the MySQL AB documentation team, and is intended to provide a standard schema that can be used for examples in books, tutorials, articles, samples, and so forth.

What I really like about the Sakila database is that it contains the sample views, stored procedures, and triggers. Here is the instructions to install the sakila database on your server as well as the schema of the sakila database.

Let me know if you use any of the sample databases or build your own database. I would be interested to know what is your practice for the databases. Here is the link to how you can download and install the SQL Server sample database WideWorldImorters.

Reference: Pinal Dave (

Related Posts

What is sakila DB about?

The Sakila database is a nicely normalised schema modelling a DVD rental store, featuring things like films, actors, film-actor relationships, and a central inventory table that connects films, stores, and rentals.

How does sakila connect to database?

You can download the Sakila sample database from Click the download link and a file in Zip format will be downloaded. The Zip file contains three files: sakila-schema. sql , sakila-data.

How do I create a dummy database in MySQL?

Provide your database structure. You have 2 options to provide your database, using file submittion or pasting database schema in a textarea..
- Select tables, choose data type of each column, generate rows. User select a table and choose what data to be generated for every column. ... .
Export Database with generated data..

Does MySQL have sample database?

There are many excellent and interesting sample databases available, that you can use as a template (or pattern) to design your own databases.