Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DB ¶ added in v0.2.0
type DB struct {
// contains filtered or unexported fields
}
type DBWrapper ¶ added in v0.2.0
func NewDBWrapper ¶ added in v0.2.0
type Executor ¶
type Executor interface {
Exec(query string, args ...any) (sql.Result, error)
ExecContext(ctx context.Context, query string, args ...any) (sql.Result, error)
Prepare(query string) (*sql.Stmt, error)
PrepareContext(ctx context.Context, query string) (*sql.Stmt, error)
Query(query string, args ...any) (*sql.Rows, error)
QueryContext(ctx context.Context, query string, args ...any) (*sql.Rows, error)
QueryRow(query string, args ...any) *sql.Row
QueryRowContext(ctx context.Context, query string, args ...any) *sql.Row
}
Executor defines the common database operations that can be performed by both *sql.DB and *sql.Tx
Click to show internal directories.
Click to hide internal directories.