mysql

package
v0.0.0-...-6a8ac70 Latest Latest
Warning

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

Go to latest
Published: May 21, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DEFAULT = "common"

Functions

func GetDb

func GetDb() *gorm.DB

func GetDbByName

func GetDbByName(serviceName string) *gorm.DB

func Ping

func Ping(serviceName string) error

func RecordNotFound

func RecordNotFound(err error) bool

func RecordPlanHaveNoCriteria

func RecordPlanHaveNoCriteria(err error) bool

Types

type PgDbInfo

type PgDbInfo struct {
	ServiceName string
	DbConfig    *_var.MysqlConfigItem
	Conn        *gorm.DB
}

func LoadPgDb

func LoadPgDb(serviceName string) *PgDbInfo

func (*PgDbInfo) CheckAndReturnConn

func (info *PgDbInfo) CheckAndReturnConn() *gorm.DB

func (*PgDbInfo) InitConnect

func (info *PgDbInfo) InitConnect()

Jump to

Keyboard shortcuts

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