database

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ConnMaxLifetime = 15 * time.Minute
	MaxIdleConns    = 3
	MaxOpenConns    = 3
)

Functions

func ConnectDB

func ConnectDB(ctx context.Context, dbType, dbSource string) (*sqlx.DB, error)

func Print

func Print(rows *sqlx.Rows) error

func Query

func Query(ctx context.Context, q string, db *sqlx.DB) (*sqlx.Rows, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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