Documentation
¶
Index ¶
- Variables
- func NewTxRunner(db *sqlx.DB) *txRunner
- type BaseContextRepository
- func (r *BaseContextRepository) BindNamed(query string, arg interface{}) (string, []interface{}, error)
- func (r *BaseContextRepository) DBExec(ctx context.Context, query string, args ...interface{}) error
- func (r *BaseContextRepository) DBExecInTx(ctx context.Context, tx *sqlx.Tx, query string, args ...interface{}) error
- func (r *BaseContextRepository) DBExecReturning(ctx context.Context, dest interface{}, query string, args ...interface{}) error
- func (r *BaseContextRepository) DBExecReturningInTx(ctx context.Context, tx *sqlx.Tx, dest interface{}, query string, ...) error
- func (r *BaseContextRepository) DBGet(ctx context.Context, dest interface{}, query string, args ...interface{}) error
- func (r *BaseContextRepository) DBGetInTx(ctx context.Context, tx *sqlx.Tx, dest interface{}, query string, ...) error
- func (r *BaseContextRepository) DBNamedExec(ctx context.Context, query string, arg interface{}) error
- func (r *BaseContextRepository) DBNamedExecInTx(ctx context.Context, tx *sqlx.Tx, query string, arg interface{}) error
- func (r *BaseContextRepository) DBNamedExecReturning(ctx context.Context, dest interface{}, query string, arg interface{}) error
- func (r *BaseContextRepository) DBNamedExecReturningInTx(ctx context.Context, tx *sqlx.Tx, dest interface{}, query string, ...) error
- func (r *BaseContextRepository) DBSelect(ctx context.Context, dest interface{}, query string, args ...interface{}) error
- func (r *BaseContextRepository) DBSelectInTx(ctx context.Context, tx *sqlx.Tx, dest interface{}, query string, ...) error
- func (r *BaseContextRepository) DBSoftExec(ctx context.Context, query string, args ...interface{}) error
- func (r *BaseContextRepository) DBSoftExecInTx(ctx context.Context, tx *sqlx.Tx, query string, args ...interface{}) error
- type BaseRepository
- func (r *BaseRepository) DBExec(query string, args ...interface{}) error
- func (r *BaseRepository) DBExecInTx(tx *sqlx.Tx, query string, args ...interface{}) error
- func (r *BaseRepository) DBExecReturning(dest interface{}, query string, args ...interface{}) error
- func (r *BaseRepository) DBExecReturningInTx(tx *sqlx.Tx, dest interface{}, query string, args ...interface{}) error
- func (r *BaseRepository) DBGet(dest interface{}, query string, args ...interface{}) error
- func (r *BaseRepository) DBGetInTx(tx *sqlx.Tx, dest interface{}, query string, args ...interface{}) error
- func (r *BaseRepository) DBSelect(dest interface{}, query string, args ...interface{}) error
- func (r *BaseRepository) DBSelectInTx(tx *sqlx.Tx, dest interface{}, query string, args ...interface{}) error
- func (r *BaseRepository) DBSoftExec(query string, args ...interface{}) error
- func (r *BaseRepository) DBSoftExecInTx(tx *sqlx.Tx, query string, args ...interface{}) error
- type TxRunner
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrZeroRowsAffected = errors.New("no rows affected")
)
Functions ¶
func NewTxRunner ¶
Types ¶
type BaseContextRepository ¶
type BaseContextRepository struct {
// contains filtered or unexported fields
}
func NewBaseContextRepository ¶
func NewBaseContextRepository(db *sqlx.DB, appName string, tableName string) BaseContextRepository
func (*BaseContextRepository) BindNamed ¶
func (r *BaseContextRepository) BindNamed(query string, arg interface{}) (string, []interface{}, error)
func (*BaseContextRepository) DBExec ¶
func (r *BaseContextRepository) DBExec(ctx context.Context, query string, args ...interface{}) error
func (*BaseContextRepository) DBExecInTx ¶
func (*BaseContextRepository) DBExecReturning ¶
func (r *BaseContextRepository) DBExecReturning(ctx context.Context, dest interface{}, query string, args ...interface{}) error
func (*BaseContextRepository) DBExecReturningInTx ¶
func (*BaseContextRepository) DBGet ¶
func (r *BaseContextRepository) DBGet(ctx context.Context, dest interface{}, query string, args ...interface{}) error
func (*BaseContextRepository) DBNamedExec ¶
func (r *BaseContextRepository) DBNamedExec(ctx context.Context, query string, arg interface{}) error
func (*BaseContextRepository) DBNamedExecInTx ¶
func (*BaseContextRepository) DBNamedExecReturning ¶
func (r *BaseContextRepository) DBNamedExecReturning(ctx context.Context, dest interface{}, query string, arg interface{}) error
func (*BaseContextRepository) DBNamedExecReturningInTx ¶
func (*BaseContextRepository) DBSelect ¶
func (r *BaseContextRepository) DBSelect(ctx context.Context, dest interface{}, query string, args ...interface{}) error
func (*BaseContextRepository) DBSelectInTx ¶
func (*BaseContextRepository) DBSoftExec ¶
func (r *BaseContextRepository) DBSoftExec(ctx context.Context, query string, args ...interface{}) error
func (*BaseContextRepository) DBSoftExecInTx ¶
type BaseRepository ¶
type BaseRepository struct {
// contains filtered or unexported fields
}
func NewBaseRepository ¶
func NewBaseRepository(db *sqlx.DB, appName string, tableName string) BaseRepository
func (*BaseRepository) DBExec ¶
func (r *BaseRepository) DBExec(query string, args ...interface{}) error
func (*BaseRepository) DBExecInTx ¶
func (r *BaseRepository) DBExecInTx(tx *sqlx.Tx, query string, args ...interface{}) error
func (*BaseRepository) DBExecReturning ¶
func (r *BaseRepository) DBExecReturning(dest interface{}, query string, args ...interface{}) error
func (*BaseRepository) DBExecReturningInTx ¶
func (r *BaseRepository) DBExecReturningInTx(tx *sqlx.Tx, dest interface{}, query string, args ...interface{}) error
func (*BaseRepository) DBGet ¶
func (r *BaseRepository) DBGet(dest interface{}, query string, args ...interface{}) error
func (*BaseRepository) DBGetInTx ¶
func (r *BaseRepository) DBGetInTx(tx *sqlx.Tx, dest interface{}, query string, args ...interface{}) error
func (*BaseRepository) DBSelect ¶
func (r *BaseRepository) DBSelect(dest interface{}, query string, args ...interface{}) error
func (*BaseRepository) DBSelectInTx ¶
func (r *BaseRepository) DBSelectInTx(tx *sqlx.Tx, dest interface{}, query string, args ...interface{}) error
func (*BaseRepository) DBSoftExec ¶
func (r *BaseRepository) DBSoftExec(query string, args ...interface{}) error
func (*BaseRepository) DBSoftExecInTx ¶
func (r *BaseRepository) DBSoftExecInTx(tx *sqlx.Tx, query string, args ...interface{}) error
Click to show internal directories.
Click to hide internal directories.