sqlite

package
v0.0.0-...-d06d904 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildBodySqlStr

func BuildBodySqlStr(andStr, colName string) string

func GetBodyAndWhereVal

func GetBodyAndWhereVal(existingVal any) any

func GetInsert

func GetInsert(tbl int) string

func GetSelect

func GetSelect(tbl int) string

func GetUpdate

func GetUpdate(tbl int) string

Types

type Repo

type Repo struct {
	Port int
	Mtx  sync.Mutex
	// contains filtered or unexported fields
}

Basic type to encapsulate the various IRepository methods

var AppRepo Repo

Repo used by the app

func SetupRepo

func SetupRepo(conn string, dbKind godoo.DbType, dateLayout string, port int) *Repo

func (*Repo) Add

func (r *Repo) Add(itm *godoo.TodoItem) (int64, error)

func (*Repo) GetAll

func (r *Repo) GetAll() ([]godoo.TodoItem, error)

func (*Repo) GetWhere

func (r *Repo) GetWhere(qry godoo.FullUserQuery) ([]godoo.TodoItem, error)

func (*Repo) UpdateWhere

func (r *Repo) UpdateWhere(srchQry, edtQry godoo.FullUserQuery) (int, error)

Jump to

Keyboard shortcuts

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