sqlite

package
v0.0.0-...-6bc2ae1 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2018 License: LGPL-2.1 Imports: 4 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDialect

func NewDialect() qb.Dialect

NewDialect creates a new sqlite3 dialect

Types

type Dialect

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

Dialect is a type of dialect that can be used with sqlite driver

func (*Dialect) AutoIncrement

func (d *Dialect) AutoIncrement(column *qb.ColumnElem) string

AutoIncrement generates auto increment sql of current dialect

func (*Dialect) CompileType

func (d *Dialect) CompileType(t qb.TypeElem) string

CompileType compiles a type into its DDL

func (*Dialect) Driver

func (d *Dialect) Driver() string

Driver returns the current driver of dialect

func (*Dialect) Escape

func (d *Dialect) Escape(str string) string

Escape wraps the string with escape characters of the dialect

func (*Dialect) EscapeAll

func (d *Dialect) EscapeAll(strings []string) []string

EscapeAll wraps all elements of string array

func (*Dialect) Escaping

func (d *Dialect) Escaping() bool

Escaping gets the escaping parameter of dialect

func (*Dialect) GetCompiler

func (d *Dialect) GetCompiler() qb.Compiler

GetCompiler returns a SqliteCompiler

func (*Dialect) SetEscaping

func (d *Dialect) SetEscaping(escaping bool)

SetEscaping sets the escaping parameter of dialect

func (*Dialect) SupportsUnsigned

func (d *Dialect) SupportsUnsigned() bool

SupportsUnsigned returns whether driver supports unsigned type mappings or not

func (*Dialect) WrapError

func (d *Dialect) WrapError(err error) qb.Error

WrapError wraps a native error in a qb Error

type SqliteCompiler

type SqliteCompiler struct {
	qb.SQLCompiler
}

SqliteCompiler is a SQLCompiler specialised for Sqlite

func (SqliteCompiler) VisitUpsert

func (SqliteCompiler) VisitUpsert(context *qb.CompilerContext, upsert qb.UpsertStmt) string

VisitUpsert generates the following sql: REPLACE INTO ... VALUES ...

Jump to

Keyboard shortcuts

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