user

package
v0.0.0-...-9edd19e Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2018 License: BSD-3-Clause Imports: 4 Imported by: 0

README

  1. Import ./users.sql in postgres
  2. Build sqrible : make -C ../../ build
  3. Run: PGDATABASE=yourdb PGHOST=localhost ../../bin/sqrible -c ./sqrible.yml -d ./templates/ -t users | goimports > generated.go

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PrepareQueryRow

func PrepareQueryRow(db Queryer, name, sql string, args ...interface{}) *pgx.Row

func PreparedName

func PreparedName(baseName, sql string) string

Types

type Preparer

type Preparer interface {
	Prepare(name, sql string) (*pgx.PreparedStatement, error)
}

type Queryer

type Queryer interface {
	Query(sql string, args ...interface{}) (*pgx.Rows, error)
	QueryRow(sql string, args ...interface{}) *pgx.Row
	Exec(sql string, arguments ...interface{}) (pgx.CommandTag, error)
}

Jump to

Keyboard shortcuts

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