mysql

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: May 21, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetORM

func GetORM() *gorm.DB

GetORM return default *gorm.DB

func GetORMByName

func GetORMByName(name string) *gorm.DB

GetORMByName get orm by name

func InitDB

func InitDB(list []*DBConfig) (err error)

func InitDefaultDB

func InitDefaultDB(db *DBConfig) (err error)

Types

type DBConfig

type DBConfig struct {
	Name            string
	User            string
	Password        string
	Host            string
	Port            int
	Debug           bool
	DisablePrepared bool
}

Jump to

Keyboard shortcuts

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