MCPcopy Create free account
hub / github.com/go-pg/pg / QueryOne

Method QueryOne

orm/query.go:1288–1291  ·  view source on GitHub ↗

QueryOne is an alias for DB.QueryOne.

(model, query interface{}, params ...interface{})

Source from the content-addressed store, hash-verified

1286
1287// QueryOne is an alias for DB.QueryOne.
1288func (q *Query) QueryOne(model, query interface{}, params ...interface{}) (Result, error) {
1289 params = append(params, q.tableModel)
1290 return q.db.QueryOneContext(q.ctx, model, query, params...)
1291}
1292
1293// CopyFrom is an alias from DB.CopyFrom.
1294func (q *Query) CopyFrom(r io.Reader, query interface{}, params ...interface{}) (Result, error) {

Callers

nothing calls this directly

Calls 1

QueryOneContextMethod · 0.65

Tested by

no test coverage detected