Documentation ¶
Index ¶
- func CreateBibView(database *sql.DB, cols []string, idAttr string) error
- func CreateSchema(database *sql.DB, structures map[string][]string, indexedCols []string, ...) error
- func DropExisting(database *sql.DB) error
- func GenerateColCountNames(colCount []int) []string
- func OpenDatabase(dbPath string) (*sql.DB, error)
- func PrepareInsert(database *sql.Tx, table string, cols []string) (*sql.Stmt, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateBibView ¶
CreateBibView creates a database view needed by liveattrs to fetch bibliography information.
func CreateSchema ¶
func CreateSchema(database *sql.DB, structures map[string][]string, indexedCols []string, useSelfJoin bool, countColumns []int) error
CreateSchema creates all the required tables, views and indices
func DropExisting ¶
DropExisting drops existing tables/views. It is safe to call this even if one or more of these does not exist.
func GenerateColCountNames ¶
GenerateColCountNames creates a list of general column names for positional attributes we would like to count. E.g. in case we want [0, 1, 3] (this can be something like 'word', 'lemma' )
func OpenDatabase ¶
OpenDatabase opens a sqlite3 database specified by its filesystem path. In case of an error it panics.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.