sqlite

package
v0.0.0-...-2d44628 Latest Latest
Warning

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

Go to latest
Published: Nov 3, 2025 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NormalizeError

func NormalizeError(err error) error

NormalizeError wraps the error with additional information if present.

func RunOptimizer

func RunOptimizer(ctx context.Context, db *sql.DB) error

RunOptimizer runs an sqlite database periodic optimizer task.

func WithErrorChecking

func WithErrorChecking(res sql.Result, err error) error

WithErrorChecking handles executed query errors.

Types

type Builder

type Builder struct {
	// contains filtered or unexported fields
}

Builder is an SQLite client builder.

func NewDB

func NewDB(filename string) *Builder

NewDB creates an SQLite client.

func (*Builder) Connect

func (c *Builder) Connect() *bun.DB

Connect to the database.

func (*Builder) WithDebugLogging

func (c *Builder) WithDebugLogging() *Builder

WithDebugLogging configures the client with query logging.

Jump to

Keyboard shortcuts

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