Documentation ¶
Index ¶
- type AQLConn
- type AQLDriver
- type AQLRowser
- type Column
- type Row
- type Rows
- type Stmt
- func (stmt *Stmt) Close() error
- func (stmt *Stmt) Exec(args []driver.Value) (driver.Result, error)deprecated
- func (stmt *Stmt) NumInput() int
- func (stmt *Stmt) Query(args []driver.Value) (driver.Rows, error)deprecated
- func (stmt *Stmt) QueryContext(ctx context.Context, args []driver.NamedValue) (driver.Rows, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AQLConn ¶
type AQLConn struct {
// contains filtered or unexported fields
}
func (*AQLConn) Close ¶
Close invalidates and potentially stops any current prepared statements and transactions, marking this connection as no longer in use.
Because the sql package maintains a free pool of connections and only calls Close when there's a surplus of idle connections, it shouldn't be necessary for drivers to do their own connection caching.
Drivers must ensure all network calls made by Close do not block indefinitely (e.g. apply a timeout).
func (*AQLConn) PrepareContext ¶
type Rows ¶
type Rows struct {
// contains filtered or unexported fields
}
func (*Rows) Columns ¶
Columns returns the names of the columns. The number of columns of the result is inferred from the length of the slice. If a particular column name isn't known, an empty string should be returned for that entry.
func (*Rows) NamedColumns ¶
func (*Rows) Next ¶
Next is called to populate the next row of data into the provided slice. The provided slice will be the same size as the Columns() are wide.
Next should return io.EOF when there are no more rows.
The dest should not be written to outside of Next. Care should be taken when closing Rows not to modify a buffer held in dest.
type Stmt ¶
type Stmt struct {
// contains filtered or unexported fields
}
func (*Stmt) Close ¶
Close closes the statement. As of Go 1.1, a Stmt will not be closed if it's in use by any queries.
Drivers must ensure all network calls made by Close do not block indefinitely (e.g. apply a timeout).
func (*Stmt) NumInput ¶
NumInput returns the number of placeholder parameters.
If NumInput returns >= 0, the sql package will sanity check argument counts from callers and return errors to the caller before the statement's Exec or Query methods are called.
NumInput may also return -1, if the driver doesn't know its number of placeholders. In that case, the sql package will not sanity check Exec or Query argument counts.
func (*Stmt) QueryContext ¶
QueryContext executes a query that may return rows, such as a SELECT.
QueryContext must honor the context timeout and return when it is canceled.