Versions in this module Expand all Collapse all v0 v0.0.8 Oct 11, 2024 Changes in this version + type BatchCreateParams struct + Author []string + ID []string + Title []string + UpdateTime []int64 + type Book struct + Author string + ID string + Title string + UpdateTime int64 + type CreateParams struct + Author string + ID string + Title string + UpdateTime int64 + type DBTX interface + Exec func(context.Context, string, ...interface{}) (pgconn.CommandTag, error) + Query func(context.Context, string, ...interface{}) (pgx.Rows, error) + QueryRow func(context.Context, string, ...interface{}) pgx.Row + type Queries struct + func New(db DBTX) *Queries + func (q *Queries) BatchCreate(ctx context.Context, arg BatchCreateParams) (int64, error) + func (q *Queries) Create(ctx context.Context, arg CreateParams) error + func (q *Queries) Delete(ctx context.Context, id string) error + func (q *Queries) Get(ctx context.Context, id string) (Book, error) + func (q *Queries) List(ctx context.Context) ([]Book, error) + func (q *Queries) Update(ctx context.Context, arg UpdateParams) error + func (q *Queries) Upsert(ctx context.Context, arg UpsertParams) error + func (q *Queries) WithTx(tx pgx.Tx) *Queries + type UpdateParams struct + Author string + ID string + SetAuthor bool + Title string + UpdateTime int64 + type UpsertParams struct + Author string + ID string + Title string + UpdateTime int64