sqlite

package
v1.0.9 Latest Latest
Warning

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

Go to latest
Published: May 22, 2025 License: GPL-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Type__bool

func Type__bool(f attrs.Field) string

func Type__datetime

func Type__datetime(f attrs.Field) string

func Type__float

func Type__float(f attrs.Field) string

func Type__int

func Type__int(f attrs.Field) string

func Type__string

func Type__string(f attrs.Field) string

Types

type SQLiteSchemaEditor

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

func NewSQLiteSchemaEditor

func NewSQLiteSchemaEditor(db *sql.DB) *SQLiteSchemaEditor

func (*SQLiteSchemaEditor) AddField

func (m *SQLiteSchemaEditor) AddField(table migrator.Table, col migrator.Column) error

func (*SQLiteSchemaEditor) AddIndex

func (m *SQLiteSchemaEditor) AddIndex(table migrator.Table, index migrator.Index) error

func (*SQLiteSchemaEditor) AlterField

func (m *SQLiteSchemaEditor) AlterField(
	table migrator.Table,
	oldCol migrator.Column,
	newCol migrator.Column,
) error

func (*SQLiteSchemaEditor) CreateTable

func (m *SQLiteSchemaEditor) CreateTable(table migrator.Table) error

func (*SQLiteSchemaEditor) DropIndex

func (m *SQLiteSchemaEditor) DropIndex(table migrator.Table, index migrator.Index) error

func (*SQLiteSchemaEditor) DropTable

func (m *SQLiteSchemaEditor) DropTable(table migrator.Table) error

func (*SQLiteSchemaEditor) Execute

func (m *SQLiteSchemaEditor) Execute(ctx context.Context, query string, args ...any) (sql.Result, error)

func (*SQLiteSchemaEditor) HasMigration

func (m *SQLiteSchemaEditor) HasMigration(appName string, modelName string, migrationName string) (bool, error)

func (*SQLiteSchemaEditor) RemoveField

func (m *SQLiteSchemaEditor) RemoveField(table migrator.Table, col migrator.Column) error

func (*SQLiteSchemaEditor) RemoveMigration

func (m *SQLiteSchemaEditor) RemoveMigration(appName string, modelName string, migrationName string) error

func (*SQLiteSchemaEditor) RenameIndex

func (m *SQLiteSchemaEditor) RenameIndex(table migrator.Table, oldName string, newName string) error

func (*SQLiteSchemaEditor) RenameTable

func (m *SQLiteSchemaEditor) RenameTable(table migrator.Table, newName string) error

func (*SQLiteSchemaEditor) Setup

func (m *SQLiteSchemaEditor) Setup() error

func (*SQLiteSchemaEditor) StoreMigration

func (m *SQLiteSchemaEditor) StoreMigration(appName string, modelName string, migrationName string) error

func (*SQLiteSchemaEditor) WriteColumn

func (m *SQLiteSchemaEditor) WriteColumn(w *strings.Builder, col migrator.Column)

Jump to

Keyboard shortcuts

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