Documentation
¶
Index ¶
- Variables
- type Batch
- type BatchResults
- type Conn
- func (conn *Conn) Begin(ctx context.Context) (*Tx, error)
- func (conn *Conn) BeginFunc(ctx context.Context, f func(*Tx) error) error
- func (conn *Conn) BeginTx(ctx context.Context, txOptions pgx.TxOptions) (*Tx, error)
- func (conn *Conn) BeginTxFunc(ctx context.Context, txOptions pgx.TxOptions, f func(*Tx) error) error
- func (conn *Conn) Close(ctx context.Context) error
- func (conn *Conn) Conn() *pgx.Conn
- func (conn *Conn) CopyFrom(ctx context.Context, tableName Identifier, rowSrc interface{}) (int64, error)
- func (conn *Conn) Exec(ctx context.Context, query string, args ...interface{}) (pgconn.CommandTag, error)
- func (conn *Conn) Find(ctx context.Context, dest interface{}, query string, args ...interface{}) error
- func (conn *Conn) FindAll(ctx context.Context, dest interface{}, query string, args ...interface{}) error
- func (conn *Conn) Ping(ctx context.Context) error
- func (conn *Conn) Prepare(ctx context.Context, query string, examples ...interface{}) (*Stmt, error)
- func (conn *Conn) Query(ctx context.Context, query string, args ...interface{}) (*Rows, error)
- func (conn *Conn) SendBatch(ctx context.Context, batch *Batch) *BatchResults
- type CopyFromFn
- type DB
- func (db *DB) Begin(ctx context.Context) (*Tx, error)
- func (db *DB) BeginTx(ctx context.Context, opts pgx.TxOptions) (*Tx, error)
- func (db *DB) Close() error
- func (db *DB) CopyFrom(ctx context.Context, tableName Identifier, rowSrc interface{}) (int64, error)
- func (db *DB) Exec(ctx context.Context, query string, args ...interface{}) (pgconn.CommandTag, error)
- func (db *DB) Find(ctx context.Context, dest interface{}, query string, args ...interface{}) error
- func (db *DB) FindAll(ctx context.Context, dest interface{}, query string, args ...interface{}) error
- func (db *DB) Ping(ctx context.Context) error
- func (db *DB) Pool() *pgxpool.Pool
- func (db *DB) Prepare(ctx context.Context, query string, examples ...interface{}) (*PooledStmt, error)
- func (db *DB) Query(ctx context.Context, query string, args ...interface{}) (*Rows, error)
- func (db *DB) SendBatch(ctx context.Context, batch *Batch) *BatchResults
- type ExecFn
- type Identifier
- type PooledStmt
- func (stmt *PooledStmt) Close(ctx context.Context) error
- func (stmt *PooledStmt) Exec(ctx context.Context, args ...interface{}) (pgconn.CommandTag, error)
- func (stmt *PooledStmt) Query(ctx context.Context, args ...interface{}) (*Rows, error)
- func (stmt *PooledStmt) Stmt() *pgconn.StatementDescription
- type PrepareFn
- type QueryFn
- type Rows
- type Stmt
- type Tx
- func (tx *Tx) Begin(ctx context.Context) (*Tx, error)
- func (tx *Tx) BeginFunc(ctx context.Context, f func(*Tx) error) error
- func (tx *Tx) Commit(ctx context.Context) error
- func (tx *Tx) CopyFrom(ctx context.Context, tableName Identifier, rowSrc interface{}) (int64, error)
- func (tx *Tx) Exec(ctx context.Context, query string, args ...interface{}) (pgconn.CommandTag, error)
- func (tx *Tx) Find(ctx context.Context, dest interface{}, query string, args ...interface{}) error
- func (tx *Tx) FindAll(ctx context.Context, dest interface{}, query string, args ...interface{}) error
- func (tx *Tx) Prepare(ctx context.Context, query string, examples ...interface{}) (*Stmt, error)
- func (tx *Tx) Query(ctx context.Context, query string, args ...interface{}) (*Rows, error)
- func (tx *Tx) Rollback(ctx context.Context) error
- func (tx *Tx) SendBatch(ctx context.Context, batch *Batch) *BatchResults
- func (tx *Tx) Tx() pgx.Tx
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrEmptySlice = errors.New("kra: empty slice")
Functions ¶
This section is empty.
Types ¶
type BatchResults ¶
type BatchResults struct {
// contains filtered or unexported fields
}
func (*BatchResults) BatchResults ¶
func (batchResults *BatchResults) BatchResults() pgx.BatchResults
func (*BatchResults) Close ¶
func (batchResults *BatchResults) Close() error
func (*BatchResults) Exec ¶
func (batchResults *BatchResults) Exec() (pgconn.CommandTag, error)
func (*BatchResults) Query ¶
func (batchResults *BatchResults) Query() (*Rows, error)
type Conn ¶
type Conn struct {
// contains filtered or unexported fields
}
func (*Conn) BeginTxFunc ¶
type CopyFromFn ¶
type CopyFromFn func(ctx context.Context, tableName pgx.Identifier, columnNames []string, rowSrc pgx.CopyFromSource) (int64, error)
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
type Identifier ¶
type Identifier pgx.Identifier
type PooledStmt ¶
type PooledStmt struct {
// contains filtered or unexported fields
}
func (*PooledStmt) Exec ¶
func (stmt *PooledStmt) Exec(ctx context.Context, args ...interface{}) (pgconn.CommandTag, error)
func (*PooledStmt) Query ¶
func (stmt *PooledStmt) Query(ctx context.Context, args ...interface{}) (*Rows, error)
func (*PooledStmt) Stmt ¶
func (stmt *PooledStmt) Stmt() *pgconn.StatementDescription
type Stmt ¶
type Stmt struct {
// contains filtered or unexported fields
}
func (*Stmt) Stmt ¶
func (stmt *Stmt) Stmt() *pgconn.StatementDescription
Click to show internal directories.
Click to hide internal directories.