(ctx context.Context, query string, nargs []driver.NamedValue)
| 49 | } |
| 50 | |
| 51 | func (c *PgConn) QueryContext(ctx context.Context, query string, nargs []driver.NamedValue) (driver.Rows, error) { |
| 52 | args := make([]driver.Value, len(nargs)) |
| 53 | for _, v := range nargs { |
| 54 | args[(v.Ordinal - 1)] = v.Value |
| 55 | } |
| 56 | |
| 57 | st, err := c.Prepare(query) |
| 58 | if err != nil { |
| 59 | return nil, err |
| 60 | } |
| 61 | return st.Query(args) |
| 62 | } |
| 63 | |
| 64 | func (c *PgConn) Close() error { |
| 65 | return nil |