database

package
v1.0.6 Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DB

type DB struct {
	*sqlx.DB
}

DB is a database instance

func Open

func Open(host, port, dbname, user, password string) (*DB, error)

Open opens a Postgres database connection with given values

func (*DB) PerformMigrations

func (db *DB) PerformMigrations() error

PerformMigrations migrates database to newest version using migration files under svenska-yle-bot/database/migrations

Jump to

Keyboard shortcuts

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