- Qt 5.15
- Qt SQL
- Qt SQL C++ Classes
- Qt 5.15.15 Reference Documentation

# Qt SQL C++ Classes

Provides a driver layer, SQL API layer, and a user interface layer for SQL databases. More...

## Namespaces

QSql | Contains miscellaneous identifiers used throughout the Qt SQL module

## Classes

QSqlDatabase | Handles a connection to a database
QSqlDriver | Abstract base class for accessing specific SQL databases
QSqlDriverCreator | Template class that provides a SQL driver factory for a specific driver type
QSqlDriverCreatorBase | The base class for SQL driver factories
QSqlDriverPlugin | Abstract base for custom QSqlDriver plugins
QSqlError | SQL database error information
QSqlField | Manipulates the fields in SQL database tables and views
QSqlIndex | Functions to manipulate and describe database indexes
QSqlQuery | Means of executing and manipulating SQL statements
QSqlQueryModel | Read-only data model for SQL result sets
QSqlRecord | Encapsulates a database record
QSqlRelation | Stores information about an SQL foreign key
QSqlRelationalDelegate | Delegate that is used to display and edit data from a QSqlRelationalTableModel
QSqlRelationalTableModel | Editable data model for a single database table, with foreign key support
QSqlResult | Abstract interface for accessing data from specific SQL databases
QSqlTableModel | Editable data model for a single database table

## Detailed Description

To include the definitions of the module's classes, use the following directive:

     #include <QtSql>

To link against the module, add this line to your qmake `.pro` file:

     QT += sql

See the SQL Programming guide for information about using this module in your applications.