persistence

package
v0.0.0-...-8305c4b Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SELECTACCOUNTINFO = "SELECT  a.id, a.number, u.name, u.email FROM accounts a INNER JOIN users u ON a.user_id=u.id WHERE a.number = $1"
)

Variables

This section is empty.

Functions

func OpenDataBaseConnection

func OpenDataBaseConnection() (*sql.DB, error)

Types

type PostgresRepository

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

func NewPostgreRepository

func NewPostgreRepository(dbConn *sql.DB) PostgresRepository

func (PostgresRepository) GetAccountInfo

func (p PostgresRepository) GetAccountInfo(accountNumber string) (accounts.Account, error)

func (PostgresRepository) Save

func (p PostgresRepository) Save(transactions []accounts.AccountTransaction) error

Jump to

Keyboard shortcuts

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