# README
upper/db
upper/db
is a productive data access layer (DAL) for Go
that provides agnostic tools to work with different data sources, such as:
See upper.io/v4 for documentation and code samples.
The tour
Take the tour to see real live examples in your browser.
License
Licensed under MIT License
Contributors
See the list of contributors.
# Packages
No description provided by the author
# Functions
After is a comparison that means: is after the (time.Time) value.
And joins conditions under logical conjunction.
AnyOf is a comparison that means: is any of the values of the slice.
Before is a comparison that means: is before the (time.Time) value.
Between is a comparison that means: is between lowerBound and upperBound.
Eq is a comparison that means: is equal to value.
Func returns a database function expression.
Gt is a comparison that means: is greater than value.
Gte is a comparison that means: is greater than or equal to value.
In is a comparison that means: is any of the values.
Is is a comparison that means: is equivalent to nil, true or false.
IsNot is a comparison that means: is not equivalent to nil, true nor false.
IsNotNull is a comparison that means: is not equivalent to nil.
IsNull is a comparison that means: is equivalent to nil.
LC returns the logging collector.
Like is a comparison that checks whether the reference matches the wildcard value.
LookupAdapter returns a previously registered adapter by name.
Lt is a comparison that means: is less than value.
Lte is a comparison that means: is less than or equal to value.
NewInsertResult creates an InsertResult.
NewSettings returns a new settings value prefilled with the current default settings.
NotAnyOf is a comparison that means: is none of the values of the slice.
NotBetween is a comparison that means: is not between lowerBound and upperBound.
NotEq is a comparison that means: is not equal to value.
NotIn is a comparison that means: is none of the values.
NotLike is a comparison that checks whether the reference does not match the wildcard value.
NotRegExp is a comparison that checks whether the reference does not match the regular expression.
OnOrAfter is a comparison that means: is on or after the (time.Time) value.
OnOrBefore is a comparison that means: is on or before the (time.Time) value.
Op returns a custom comparison operator.
Open attempts to stablish a connection with a database.
Or joins conditions under logical disjunction.
Raw marks chunks of data as protected, so they pass directly to the query without any filtering.
RegExp is a comparison that checks whether the reference matches the regular expression.
RegisterAdapter registers a generic database adapter.
# Constants
Log levels.
Log levels.
Log levels.
Log levels.
Log levels.
Log levels.
Log levels.
# Variables
DefaultSettings provides default global configuration settings for database sessions.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
Error messages.
# Structs
AndExpr represents an expression joined by a logical conjuction (AND).
Comparison represents a relationship between values.
OrExpr represents a logical expression joined by logical disjunction (OR).
QueryStatus represents the status of a query after being executed.
# Interfaces
Adapter interface defines an adapter.
AfterCreateHook is an interface for records that defines an AfterCreate method that is called after creating a record.
AfterDeleteHook is an interface for records that defines a AfterDelete method that is called after removing a record.
AfterUpdateHook is an interface for records that defines an AfterUpdate method that is called after updating a record.
BatchInserter provides an interface to do massive insertions in batches.
BeforeCreateHook is an interface for records that defines an BeforeCreate method that is called before creating a record.
BeforeDeleteHook is an interface for records that defines a BeforeDelete method that is called before removing a record.
BeforeUpdateHook is an interface for records that defines a BeforeUpdate method that is called before updating a record.
Collection defines methods to work with database tables or collections.
ConnectionURL represents a data source name (DSN).
Deleter represents a DELETE statement.
HasConstraints is an interface for records that defines a Constraints method that returns the record's own constraints.
ID represents a record ID.
Inserter represents an INSERT statement.
InsertResult provides infomation about an insert operation.
Iterator provides methods for iterating over query results.
Logger represents a logging interface that is compatible with the standard "log" and with many other logging libraries.
LoggingCollector provides different methods for collecting and classifying log messages.
Marshaler is the interface implemented by struct fields that can transform themselves into values to be stored in a database.
Paginator provides tools for splitting the results of a query into chunks containing a fixed number of items.
Record is the equivalence between concrete database schemas and Go values.
Result is an interface that defines methods for result sets.
ResultMapper defined methods for a result mapper.
Selector represents a SELECT statement.
Session is an interface that defines methods for database adapters.
Settings defines methods to get or set configuration values.
SQL defines methods that can be used to build a SQL query with chainable method calls.
SQLEngine represents a SQL engine that can execute SQL queries.
SQLExecer provides methods for executing statements that do not return results.
SQLGetter provides methods for executing statements that return results.
SQLPreparer provides the Prepare and PrepareContext methods for creating prepared statements.
Store represents a data store.
StoreCreator is an interface for data stores that defines a Create method that has the task of creating a new record.
StoreDeleter is an interface for data stores that defines a Delete method that has the task of removing a record.
StoreGetter is an interface for data stores that defines a Get method that has the task of retrieving a record.
StoreSaver is an interface for data stores that defines a Save method that has the task of persisting a record.
StoreUpdater is an interface for data stores that defines a Update method that has the task of updating a record.
Unmarshaler is the interface implemented by struct fields that can transform themselves from database values into Go values.
Updater represents an UPDATE statement.
Validator is an interface for records that defines an (optional) Validate method that is called before persisting a record (creating or updating).
# Type aliases
Cond is a map that defines conditions for a query.
No description provided by the author
FuncExpr represents functions.
LogicalExpr represents an expression to be used in logical statements.
LogicalOperator represents a logical operation.
LogLevel represents a verbosity level for logs.
RawExpr represents a raw (non-filtered) expression.