database

package
v0.0.0-...-8b33ee5 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EngineMySQL    = "mysql"
	EngineSQLite   = "sqlite"
	EnginePostgres = "postgresql"
)
View Source
const (
	// Reference: https://dev.mysql.com/doc/mysql-errors/8.0/en/server-error-reference.html
	MySQLErrorCodeDuplicateEntry = 1062

	// Reference: https://www.postgresql.org/docs/13/errcodes-appendix.html
	PgSQLErrorCodeDuplicateEntry = "23505"
)

Variables

This section is empty.

Functions

func GetDBPool

func GetDBPool() dbpool.DBPool

func InitDatabase

func InitDatabase() error

func IsErrorDuplicateEntry

func IsErrorDuplicateEntry(err error) bool

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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