Documentation
¶
Index ¶
- Variables
- func And(exprs ...Expr) *logicExpr
- func Eq(column string, value any) *compExpr
- func FromString(query string, args ...any) (database.Request, error)
- func FullJoin(table, on string) joinClause
- func Gt(column string, value any) *compExpr
- func InnerJoin(table, on string) joinClause
- func LeftJoin(table, on string) joinClause
- func Like(column string, value any) *compExpr
- func Lt(column string, value any) *compExpr
- func Ne(column string, value any) *compExpr
- func Not(expr *compExpr) *notExpr
- func Null(column string) *compExpr
- func Or(exprs ...Expr) *logicExpr
- func RightJoin(table, on string) joinClause
- type ConnectionProperties
- type Expr
- type Exprs
- type From
- type JoinType
- type SelectBuilder
- func (s *SelectBuilder) Copy() *SelectBuilder
- func (s *SelectBuilder) GroupBy(fields ...string) *SelectBuilder
- func (s *SelectBuilder) Having(having string) *SelectBuilder
- func (s *SelectBuilder) Limit(limit int) *SelectBuilder
- func (s *SelectBuilder) Offset(offset int) *SelectBuilder
- func (s *SelectBuilder) OrderBy(field string, desc bool) *SelectBuilder
- func (s *SelectBuilder) Parameters() []any
- func (s *SelectBuilder) ShouldReturn() int
- func (s *SelectBuilder) ToRequest() database.Request
- func (s *SelectBuilder) Where(expr ...Expr) *SelectBuilder
- type SelectQuery
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrUnknownOperation = errors.New("unknown operation") ErrMultipleStatements = errors.New("multiple statements in query") )
View Source
var Parameterized = false
Functions ¶
Types ¶
type ConnectionProperties ¶
type From ¶
type From struct {
// contains filtered or unexported fields
}
func DistinctSelect ¶
func DistinctSelectAll ¶
func DistinctSelectAll() *From
func (From) From ¶
func (b From) From(table string, joins ...joinClause) *SelectBuilder
type SelectBuilder ¶
type SelectBuilder struct {
// contains filtered or unexported fields
}
func Count ¶
func Count(field, table string) *SelectBuilder
func (*SelectBuilder) Copy ¶
func (s *SelectBuilder) Copy() *SelectBuilder
func (*SelectBuilder) GroupBy ¶
func (s *SelectBuilder) GroupBy(fields ...string) *SelectBuilder
func (*SelectBuilder) Having ¶
func (s *SelectBuilder) Having(having string) *SelectBuilder
func (*SelectBuilder) Limit ¶
func (s *SelectBuilder) Limit(limit int) *SelectBuilder
func (*SelectBuilder) Offset ¶
func (s *SelectBuilder) Offset(offset int) *SelectBuilder
func (*SelectBuilder) OrderBy ¶
func (s *SelectBuilder) OrderBy(field string, desc bool) *SelectBuilder
func (*SelectBuilder) Parameters ¶
func (s *SelectBuilder) Parameters() []any
func (*SelectBuilder) ShouldReturn ¶
func (s *SelectBuilder) ShouldReturn() int
func (*SelectBuilder) ToRequest ¶
func (s *SelectBuilder) ToRequest() database.Request
func (*SelectBuilder) Where ¶
func (s *SelectBuilder) Where(expr ...Expr) *SelectBuilder
Click to show internal directories.
Click to hide internal directories.