database

package
v0.0.0-...-9ae858a Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Migrate

func Migrate(tx *sql.Tx) error

func Register

func Register(m *Migration)

func Setup

func Setup(tx *sql.Tx) error

Types

type BaseRunner

type BaseRunner interface {
	Execer
	Queryer
}

type Execer

type Execer interface {
	Exec(query string, args ...interface{}) (sql.Result, error)
}

type Migration

type Migration struct {
	Version     string
	Description string
	Statements  []string
	// contains filtered or unexported fields
}

type Queryer

type Queryer interface {
	Query(query string, args ...interface{}) (*sql.Rows, error)
	QueryRow(query string, args ...interface{}) *sql.Row
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳