postgres

package
v0.0.0-...-d31700d Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

func DB

func DB(name string) *pg.DB
Example
db := DB("test")
var v int64
if err := db.Query(&v, "SELECT 2019"); err != nil {
	log.Panic(v)
}
fmt.Println(v)
Output:

2019

func DefaultDB

func DefaultDB() *pg.DB

func Get

func Get(dbAddr string) *pg.DB

func New

func New(dbAddr string) *pg.DB

Types

This section is empty.

Jump to

Keyboard shortcuts

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