Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Postgres ¶
type Postgres interface {
Begin(ctx context.Context) (pgx.Tx, error)
Query(ctx context.Context, sql string, args ...interface{}) (pgx.Rows, error)
QueryRow(ctx context.Context, sql string, args ...interface{}) pgx.Row
Exec(ctx context.Context, sql string, arguments ...interface{}) (pgconn.CommandTag, error)
}
Postgres driver interface.
func NewPool ¶
func NewPool(cfg *PostgresConfig) (Postgres, error)
Creating a new postgres pool connection.
type PostgresConfig ¶
Postgres config structure.
func (*PostgresConfig) Configure ¶
func (c *PostgresConfig) Configure(cfg *pgxpool.Config)
Configure postgres driver.
Click to show internal directories.
Click to hide internal directories.