database

package
v0.0.0-...-d5f34b7 Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2014 License: GPL-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Close

func Close()

Simple

func Execute

func Execute(query string) (sql.Result, error)

Wrapper for exec, which executes a string without returning any rows. Good for basically any sql query besides SELECT

func Open

func Open() error

Self-explanatory, open a connection, but store the db as a global variable, that way parts of the code that need the database can simply call the wrapper rather than awkwardly passing around a pointer to the db

func Query

func Query(query string, args ...interface{}) (*sql.Rows, error)

Wrapper for Query

func QueryRow

func QueryRow(query string, args ...interface{}) *sql.Row

Wrapper for QueryRow

Types

This section is empty.

Directories

Path Synopsis
models

Jump to

Keyboard shortcuts

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