Qt supports several different types of SQL drivers in the form of plugins/add-ons. However, it's very easy to integrate these drivers into your Qt project. We will learn how to do this in the following example.
Setting up a database
How to do it...
Let's set up our SQL Server before we dive into Qt:
- Install and set up a MySQL Server. There are many ways you can install it. One method is to download MySQL from the official website at http://dev.mysql.com/downloads/mysql/ and install it. After that, you also need to install MySQL Workbench from http://dev.mysql.com/downloads/workbench/ to administrate your databases.
- An alternative method is to install a third-party package that comes with MySQL and other useful applications...