sqlite

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Sep 14, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SQLite

type SQLite struct{}

func New

func New() *SQLite

func (*SQLite) AdvisoryLockSQL added in v0.5.0

func (s *SQLite) AdvisoryLockSQL(key int64, mode dialect.AdvisoryLockMode) (dialect.Result, bool)

AdvisoryLockSQL reports that SQLite has no advisory-lock primitive. SQLite serializes writers at the database level, so the runtime treats advisory locks as a documented no-op (returns supported=false). The mode argument is ignored.

func (*SQLite) BuildBulkDelete

func (s *SQLite) BuildBulkDelete(table string, where *ast.WhereClause) dialect.Result

func (*SQLite) BuildBulkInsert

func (s *SQLite) BuildBulkInsert(table string, columns []string, rows [][]any) dialect.Result

func (*SQLite) BuildBulkSoftDelete

func (s *SQLite) BuildBulkSoftDelete(table string, where *ast.WhereClause) dialect.Result

func (*SQLite) BuildBulkUpdate

func (s *SQLite) BuildBulkUpdate(table string, sets []dialect.ColumnValue, where *ast.WhereClause) dialect.Result

func (*SQLite) BuildBulkUpsert

func (s *SQLite) BuildBulkUpsert(table string, columns []string, rows [][]any, conflictCols []string, updateCols []string, doNothing bool) dialect.Result

func (*SQLite) BuildDelete

func (s *SQLite) BuildDelete(table string, pkColumns []string, pkValues []any) dialect.Result

func (*SQLite) BuildDeleteVersioned added in v0.5.0

func (s *SQLite) BuildDeleteVersioned(table string, pkColumns []string, pkValues []any, versionCol string, currentVersion int) dialect.Result

BuildDeleteVersioned generates a versioned DELETE for SQLite. SQLite 3.35+ supports RETURNING; the primary key is returned so the mutation layer can detect a concurrency conflict via no-rows (mirroring Postgres).

func (*SQLite) BuildInsert

func (s *SQLite) BuildInsert(table string, columns []string, values []any, returningCols []string) dialect.Result

func (*SQLite) BuildSelect

func (s *SQLite) BuildSelect(node ast.SelectNode) dialect.Result

func (*SQLite) BuildSoftDelete

func (s *SQLite) BuildSoftDelete(table string, pkColumns []string, pkValues []any) dialect.Result

func (*SQLite) BuildSoftDeleteVersioned added in v0.5.0

func (s *SQLite) BuildSoftDeleteVersioned(table string, pkColumns []string, pkValues []any, versionCol string, currentVersion int) dialect.Result

BuildSoftDeleteVersioned generates a versioned soft-delete for SQLite. SQLite 3.35+ supports RETURNING; the primary key is returned so the mutation layer can detect a concurrency conflict via no-rows (mirroring Postgres).

func (*SQLite) BuildUpdate

func (s *SQLite) BuildUpdate(table string, changes []dialect.ColumnValue, pkColumns []string, pkValues []any) dialect.Result

func (*SQLite) BuildUpdateVersioned

func (s *SQLite) BuildUpdateVersioned(table string, changes []dialect.ColumnValue, pkColumns []string, pkValues []any, versionCol string, currentVersion int) dialect.Result

BuildUpdateVersioned generates a versioned UPDATE for SQLite. SQLite 3.35+ supports RETURNING, so the new version is returned and read back by the mutation layer (mirroring Postgres).

func (*SQLite) Explain

func (s *SQLite) Explain(query string) (string, bool)

func (*SQLite) Name added in v0.5.0

func (s *SQLite) Name() string

func (*SQLite) Now

func (s *SQLite) Now() string

func (*SQLite) SupportsReturning

func (s *SQLite) SupportsReturning() bool

func (*SQLite) UsesQuestionPlaceholders added in v0.5.0

func (s *SQLite) UsesQuestionPlaceholders() bool

Jump to

Keyboard shortcuts

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