Categorygithub.com/acoshift/pgsql
modulepackage
0.15.3
Repository: https://github.com/acoshift/pgsql.git
Documentation: pkg.go.dev

# README

pgsql

Build Status codecov Go Report Card GoDoc

pgsql is the helper functions for postgres

# Packages

No description provided by the author
No description provided by the author
No description provided by the author

# Functions

IsCharacterNotInRepertoire checks is error a character_not_in_repertoire.
IsErrorClass checks is error has given class.
IsErrorCode checks is error has given code.
IsForeignKeyViolation checks is error an foreign_key_violation.
IsInvalidTextRepresentation checks is error an invalid_text_representation.
IsQueryCanceled checks is error an query_canceled error (pq: canceling statement due to user request).
IsSerializationFailure checks is error a serialization_failure error (pq: could not serialize access due to read/write dependencies among transactions).
IsUniqueViolation checks is error an unique_violation with given constraint, constraint can be empty to ignore constraint name checks.
No description provided by the author
No description provided by the author
JSON wraps value with scanner and valuer.
No description provided by the author
NullInt64 scans null into zero int64 and convert zero into sql null.
NullString scans null into empty string and convert empty string into sql null.
NullTime likes Time but wrap time.Time with scanner.
RunInTx runs fn inside retryable transaction.
RunInTxContext runs fn inside retryable transaction with context.
Scan wraps scanner with custom scanner.

# Variables

ErrAbortTx rollbacks transaction and return nil error.

# Structs

No description provided by the author
No description provided by the author
Time is the time.Time but can scan null into empty.
TxOptions is the transaction options.

# Interfaces

BeginTxer type.
QueryContext interface.

# Type aliases

No description provided by the author
No description provided by the author