MCPcopy
hub / github.com/jackc/pgx / Begin

Method Begin

pgxpool/conn.go:106–108  ·  view source on GitHub ↗

Begin starts a transaction block from the *Conn without explicitly setting a transaction mode (see BeginTx with TxOptions if transaction mode is required).

(ctx context.Context)

Source from the content-addressed store, hash-verified

104
105// Begin starts a transaction block from the *Conn without explicitly setting a transaction mode (see BeginTx with TxOptions if transaction mode is required).
106func (c *Conn) Begin(ctx context.Context) (pgx.Tx, error) {
107 return c.Conn().Begin(ctx)
108}
109
110// BeginTx starts a transaction block from the *Conn with txOptions determining the transaction mode.
111func (c *Conn) BeginTx(ctx context.Context, txOptions pgx.TxOptions) (pgx.Tx, error) {

Callers

nothing calls this directly

Calls 2

ConnMethod · 0.95
BeginMethod · 0.65

Tested by

no test coverage detected