mysql

package
v0.0.0-...-7afedfb Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MysqlCfg

type MysqlCfg struct {
	Host        string `json:"host"`
	Password    string `json:"password"`
	Dbname      string `json:"dbname"`
	User        string `json:"user"`
	Port        int    `json:"port"`
	Charset     string `json:"charset" default:"“utf8mb4"`
	MaxIdleConn int    `json:"max_idle_conn" default:"10"`
	MaxOpenConn int    `json:"max_open_conn" default:"100"`
}

type MysqlClient

type MysqlClient struct {
	*gorm.DB
	// contains filtered or unexported fields
}

func GetInstanceGOrm

func GetInstanceGOrm(cfg *MysqlCfg) (*MysqlClient, error)

Jump to

Keyboard shortcuts

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