Returns the current (zero-based) position of the result.
.SH "QVariant QSqlResult::data ( int i )\fC [pure virtual protected]\fR"
Returns the data for field \fIi\fR (zero-based) as a QVariant. This function is only called if the result is in an active state and is positioned on a valid record and \fIi\fR is non-negative. Derived classes must reimplement this function and return the value of field \fIi\fR, or QVariant() if it cannot be determined.
.SH "bool QSqlResult::fetch ( int i )\fC [pure virtual protected]\fR"
Positions the result to an arbitrary (zero-based) index \fIi\fR. This function is only called if the result is in an active state. Derived classes must reimplement this function and position the result to the index \fIi\fR, and call setAt() with an appropriate value. Return TRUE to indicate success, or FALSE to signify failure.
Positions the result to the first record in the result. This function is only called if the result is in an active state. Derived classes must reimplement this function and position the result to the first record, and call setAt() with an appropriate value. Return TRUE to indicate success, or FALSE to signify failure.
Positions the result to the last record in the result. This function is only called if the result is in an active state. Derived classes must reimplement this function and position the result to the last record, and call setAt() with an appropriate value. Return TRUE to indicate success, or FALSE to signify failure.
Positions the result to the next available record in the result. This function is only called if the result is in an active state. The default implementation calls fetch() with the next index. Derived classes can reimplement this function and position the result to the next record in some other way, and call setAt() with an appropriate value. Return TRUE to indicate success, or FALSE to signify failure.
Positions the result to the previous available record in the result. This function is only called if the result is in an active state. The default implementation calls fetch() with the previous index. Derived classes can reimplement this function and position the result to the next record in some other way, and call setAt() with an appropriate value. Return TRUE to indicate success, or FALSE to signify failure.
Returns TRUE if the result is positioned on a valid record (that is, the result is not positioned before the first or after the last record); otherwise returns FALSE.
Sets the result to use the SQL statement \fIquery\fR for subsequent data retrieval. Derived classes must reimplement this function and apply the \fIquery\fR to the database. This function is called only after the result is set to an inactive state and is positioned before the first record of the new result. Derived classes should return TRUE if the query was successful and ready to be used, or FALSE otherwise.
.SH "void QSqlResult::setActive ( bool a )\fC [virtual protected]\fR"
Protected function provided for derived classes to set the internal active state to the value of \fIa\fR.
.PP
See also isActive().
.SH "void QSqlResult::setAt ( int at )\fC [virtual protected]\fR"
Protected function provided for derived classes to set the internal (zero-based) result index to \fIat\fR.
Sets forward only mode to \fIforward\fR. If forward is TRUE only fetchNext() is allowed for navigating the results. Forward only mode needs far less memory since results do not have to be cached. forward only mode is off by default.
Sets the current query for the result to \fIquery\fR. The result must be reset() in order to execute the query on the database.
.SH "void QSqlResult::setSelect ( bool s )\fC [virtual protected]\fR"
Protected function provided for derived classes to indicate whether or not the current statement is a SQL SELECT statement. The \fIs\fR parameter should be TRUE if the statement is a SELECT statement, or FALSE otherwise.