db

package
v0.0.0-...-c165996 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BeginReadOnlyTx

func BeginReadOnlyTx() *sql.Tx

func BeginTx

func BeginTx() *sql.Tx

func Close

func Close()

func Commit

func Commit(tx *sql.Tx)

func Init

func Init(c context.Context)

func UserInsert

func UserInsert(tx *sql.Tx, user *User) int64

Types

type User

type User struct {
	UserId           uint64
	UserName         string
	Email            string
	PasswordHash     string
	FirstName        string
	LastName         string
	RegistrationDate time.Time
}

func UserGetByUserName

func UserGetByUserName(tx *sql.Tx, userName string) *User

Jump to

Keyboard shortcuts

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