mysql

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2021 License: MPL-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Escape

func Escape(sql string) string

Escape escape all the unsafe characters for MySQL

func Open

func Open(config Config) (connection, error)

Open opens a database connection to MySQL database server

Types

type Config

type Config struct {
	Host         estring
	Port         uint16
	DatabaseName estring
	Username     estring
	Password     estring
}

Config represents the data used to establish database connection

func (Config) String

func (config Config) String() string

String create the MySQL DNS

Jump to

Keyboard shortcuts

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