db

package
v0.0.0-...-63a0724 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2016 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MYSQL  = "mysql"
	PGSQL  = "postgres"
	SQLITE = "sqlite3"
)

Values for driver but only MYSQL used yet

Variables

This section is empty.

Functions

func Add

func Add(connName, driverName, dataSourceName string) error

Add connection to a pool of connections

Types

type Conn

type Conn struct {
	DSN    string
	Driver string
	sqlx.DB
}

Conn represents single connection to DB

func Use

func Use(name string) *Conn

Use established connection from the pool.

type Driver

type Driver string

Driver represents type of a database

Jump to

Keyboard shortcuts

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