QueryContext allows calling the underlying QueryContext method of the transaction if it is supported by it. See, database/sql#Tx.QueryContext for more information.
(ctx context.Context, query string, args ...any)
| 271 | // QueryContext allows calling the underlying QueryContext method of the transaction if it is supported by it. |
| 272 | // See, database/sql#Tx.QueryContext for more information. |
| 273 | func (tx *txDriver) QueryContext(ctx context.Context, query string, args ...any) (*stdsql.Rows, error) { |
| 274 | q, ok := tx.tx.(interface { |
| 275 | QueryContext(context.Context, string, ...any) (*stdsql.Rows, error) |
| 276 | }) |
| 277 | if !ok { |
| 278 | return nil, fmt.Errorf("Tx.QueryContext is not supported") |
| 279 | } |
| 280 | return q.QueryContext(ctx, query, args...) |
| 281 | } |
nothing calls this directly
no outgoing calls
no test coverage detected