postgres

package
v0.0.0-...-29e199f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 5, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Overview

Package postgres defines the PostgresSQL functionalities.

Index

Constants

View Source
const (
	DialectName = "postgres"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Postgres

type Postgres struct {
	// contains filtered or unexported fields
}

func (*Postgres) CloseConnection

func (p *Postgres) CloseConnection(_ context.Context) error

func (*Postgres) Connect

func (p *Postgres) Connect(connectionData sqlfw.ConnectionData) (*sqlx.DB, error)

func (*Postgres) GetConnectionData

func (p *Postgres) GetConnectionData(config interface{}) (*sqlfw.ConnectionData, error)

func (*Postgres) GetMigrationVersion

func (p *Postgres) GetMigrationVersion(ctx context.Context) (*sqlfw.GetVersionOutput, error)

func (*Postgres) InitMigration

func (p *Postgres) InitMigration(ctx context.Context, migrationsTablePrefix *string) error

func (*Postgres) OpenConnection

func (p *Postgres) OpenConnection(ctx context.Context) error

func (*Postgres) RunMigration

func (p *Postgres) RunMigration(ctx context.Context, migration string) error

func (*Postgres) SetMigrationVersion

func (p *Postgres) SetMigrationVersion(ctx context.Context, input sqlfw.SetVersionInput) error

func (*Postgres) TranslateError

func (p *Postgres) TranslateError(_ context.Context, err error, defaultError error) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL