/
githubmirror
/
sqlc
Обзор
Документация
Войти
/
githubmirror
/
sqlc
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
examples/authors/postgresql/db.go
32 строки
569 B
Kyle Gray
Release 1.31.1 (#4407)
22 апр 2026, 17:52
Не верифицирован
22 апр 2026, 17:52
a95e91d
Код
Авторство
О чём код?
// Code generated by sqlc. DO NOT EDIT. // versions: // sqlc v1.31.1 package authors import ( "context" "github.com/jackc/pgx/v5" "github.com/jackc/pgx/v5/pgconn" ) type DBTX interface { Exec(context.Context, string, ...interface{}) (pgconn.CommandTag, error) Query(context.Context, string, ...interface{}) (pgx.Rows, error) QueryRow(context.Context, string, ...interface{}) pgx.Row } func New(db DBTX) *Queries { return &Queries{db: db} } type Queries struct { db DBTX } func (q *Queries) WithTx(tx pgx.Tx) *Queries { return &Queries{ db: tx, } }