Documentation
¶
Overview ¶
Package sql3util implements SQLite utilities.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NamedArg ¶
NamedArg splits an named arg into a key and value, around an equals sign. Spaces are trimmed around both key and value.
func ValidPageSize ¶
ValidPageSize returns true if s is a valid page size.
Types ¶
type Column ¶
type Column struct {
Name string
Type string
Length string
ConstraintName string
Comment string
IsPrimaryKey bool
IsAutoIncrement bool
IsNotNull bool
IsUnique bool
PKOrder OrderClause
PKConflictClause ConflictClause
NotNullConflictClause ConflictClause
UniqueConflictClause ConflictClause
CheckExpr string
DefaultExpr string
CollateName string
ForeignKeyClause *ForeignKey
}
Column holds metadata about a column.
type ConflictClause ¶
type ConflictClause uint32
const ( CONFLICT_NONE ConflictClause = iota CONFLICT_ROLLBACK CONFLICT_ABORT CONFLICT_FAIL CONFLICT_IGNORE CONFLICT_REPLACE )
type ForeignKey ¶
type OrderClause ¶
type OrderClause uint32
const ( ORDER_NONE OrderClause = iota ORDER_ASC ORDER_DESC )
type StatementType ¶
type StatementType uint32
const ( CREATE_UNKNOWN StatementType = iota CREATE_TABLE ALTER_RENAME_TABLE ALTER_RENAME_COLUMN ALTER_ADD_COLUMN ALTER_DROP_COLUMN )
type Table ¶
type Table struct {
Name string
Schema string
Comment string
IsTemporary bool
IsIfNotExists bool
IsWithoutRowID bool
IsStrict bool
Columns []Column
Type StatementType
CurrentName string
NewName string
}
Table holds metadata about a table.
func ParseTable ¶
ParseTable parses a CREATE or ALTER TABLE command.
Click to show internal directories.
Click to hide internal directories.