MCPcopy
hub / github.com/jmoiron/sqlx / PreparexContext

Method PreparexContext

sqlx_context.go:254–256  ·  view source on GitHub ↗

PreparexContext returns an sqlx.Stmt instead of a sql.Stmt. The provided context is used for the preparation of the statement, not for the execution of the statement.

(ctx context.Context, query string)

Source from the content-addressed store, hash-verified

252// The provided context is used for the preparation of the statement, not for
253// the execution of the statement.
254func (c *Conn) PreparexContext(ctx context.Context, query string) (*Stmt, error) {
255 return PreparexContext(ctx, c, query)
256}
257
258// QueryxContext queries the database and returns an *sqlx.Rows.
259// Any placeholder parameters are replaced with supplied args.

Callers

nothing calls this directly

Calls 1

PreparexContextFunction · 0.85

Tested by

no test coverage detected