MySQL++ Reference Manual

- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

# mysqlpp::StoreQueryResult Class Reference

StoreQueryResult set type for "store" queries. More...

`#include <result.h>`

Inheritance diagram for mysqlpp::StoreQueryResult:

[legend]
Collaboration diagram for mysqlpp::StoreQueryResult:

[legend]
List of all members.

## Public Types
typedef std::vector< Row > | list_type
| type of vector base class
## Public Member Functions
| StoreQueryResult ()
| Default constructor.
| StoreQueryResult (MYSQL_RES *result, DBDriver *dbd, bool te=true)
| Fully initialize object.
| StoreQueryResult (const StoreQueryResult &other)
| Initialize object as a copy of another StoreQueryResult object.
| ~StoreQueryResult ()
| Destroy result set.
list_type::size_type | num_rows () const
| Returns the number of rows in this result set.
StoreQueryResult & | operator= (const StoreQueryResult &rhs)
| Copy another StoreQueryResult object's data into this object.
| operator private_bool_type () const
| Test whether the query that created this result succeeded.

## Detailed Description

StoreQueryResult set type for "store" queries.

This is the obvious C++ implementation of a class to hold results from a SQL query that returns rows: a specialization of std::vector holding Row objects in memory so you get random-access semantics. MySQL++ also supports UseQueryResult which is less friendly, but has better memory performance. See the user manual for more details on the distinction and the usage patterns required.

## Member Function Documentation

mysqlpp::StoreQueryResult::operator private_bool_type | ( |  | ) | const`[inline]`

Test whether the query that created this result succeeded.

If you test this object in bool context and it's false, it's a signal that the query this was created from failed in some way. Call Query::error() or Query::errnum() to find out what exactly happened.

The documentation for this class was generated from the following files:

- result.h
- result.cpp