Home | All Classes | Main Classes | Annotated | Grouped Classes | Functions |

# QSql Class Reference

The QSql class is a namespace for Qt SQL identifiers that need to be global-like. More...

    #include <QSql>

- List of all members, including inherited members

### Public Types

- enum Confirm { Yes, No, Cancel }
- enum Location { BeforeFirst, AfterLast }
- enum Op { None, Insert, Update, Delete }
- typedef ParamType
- enum ParamTypeFlag { In, Out, InOut, Binary }
- enum TableType { Tables, SystemTables, Views, AllTables }

## Detailed Description

The QSql class is a namespace for Qt SQL identifiers that need to be global-like.

Normally, you can ignore this class. Several Qt SQL classes inherit it, so all the identifiers in the Qt SQL namespace are visible without qualification.

## Member Type Documentation

### enum QSql::Confirm

This enum type describes edit confirmations.

`QSql::Yes` |
`QSql::No` |
`QSql::Cancel` |

### enum QSql::Location

This enum type describes SQL navigation locations.

`QSql::BeforeFirst` |
`QSql::AfterLast` |

### enum QSql::Op

This enum type describes edit operations.

`QSql::None` |
`QSql::Insert` |
`QSql::Update` |
`QSql::Delete` |

### enum QSql::ParamTypeFlag
typedef QSql::ParamType

This enum is used to set the type of a bind parameter

`QSql::In` | the bind parameter is used to put data into the database
`QSql::Out` | the bind parameter is used to receive data from the database
`QSql::InOut` | the bind parameter is used to put data into the database; it will be overwritten with output data on executing a query.
`QSql::Binary` | this must be OR'd with one of the other flags if you want to indicate that the data being transferred is raw binary data

The ParamType typedef can store a combination of ParamTypeFlag values.

### enum QSql::TableType

This enum type describes types of tables

`QSql::Tables` | All the tables visible to the user
`QSql::SystemTables` | Internal tables used by the database
`QSql::Views` | All the views visible to the user
`QSql::AllTables` | All of the above