database

package
v0.0.0-...-e5595cb Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 14, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TXHandler

func TXHandler(db *sqlx.DB, f func(*sqlx.Tx) error) (err error)

TXHandler is handler for working with transaction. This is wrapper function for commit and rollback.

Types

type SqlDb

type SqlDb struct {
	DSN string
}

func NewSqlDb

func NewSqlDb(DSN string) *SqlDb

func (*SqlDb) Open

func (s *SqlDb) Open() *sqlx.DB

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL