SetPgCatalogCache sets |pgCatalogCache| as the catalog cache instance for this session. TODO: The input type here is currently any, to avoid a package import cycle. This could be cleaned up by introducing a new interface type, in a package that does not depend on core or pgcatalog packages.
(ctx *sql.Context, pgCatalogCache any)
| 135 | // TODO: The input type here is currently any, to avoid a package import cycle. This could be cleaned up by |
| 136 | // introducing a new interface type, in a package that does not depend on core or pgcatalog packages. |
| 137 | func SetPgCatalogCache(ctx *sql.Context, pgCatalogCache any) error { |
| 138 | cv, err := getContextValues(ctx) |
| 139 | if err != nil { |
| 140 | return err |
| 141 | } |
| 142 | cv.pgCatalogCache = pgCatalogCache |
| 143 | return nil |
| 144 | } |
| 145 | |
| 146 | // SetRunnerOnContext sets the given runner within the context values. |
| 147 | func SetRunnerOnContext(ctx *sql.Context, runner sql.StatementRunner) error { |
no test coverage detected