package
1.8.94
Repository: https://github.com/macinnir/dvc.git
Documentation: pkg.go.dev

# README

Query

Performance

# https://graphviz.org/download/#mac
brew install graphviz

go test -bench=. ./core/lib/utils/query/testgen/. -cpuprofile cpu.prof
go tool pprof -svg cpu.prof > cpu.svg

go test -bench=. -trace trace.out ./core/lib/utils/query/testgen/.
go tool trace trace.out

# Data Race: Two goroutines access the same variable concurrently 
# and at least one of the accesses is a write 
# https://golang.org/doc/articles/race_detector
go test -race

# Packages

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

# Functions

And is an and statement with optional args that, if provided, are wrapped in parentheses Example: And() will result in the word `AND` being added to the where clause Example: And(EQ(1, 1), And(), And(2, 2)) will result in `AND ( 1 = 1 AND 2 = 2 )`.
Ands takes a list of args and separes them all by `AND` Example: Ands(query.EQ(1,1), query.EQ(2,2), query.EQ(3,3)) == 1 = 1 AND 2 = 2 AND 3 = 3.
Between is a BETWEEN statement Example: Between("").
BitAnd `t`.`Field` & a = b Example: query.BitAnd("foo", 2, 1) -> `t`.`Foo` & 2 = 1.
No description provided by the author
EQ is an equals statement between a table column and a value.
EQF allows for one column to be equal to another Example for a subselect query.Select(&models.UserGroupUser{}).Alias("ugu").FieldRaw("1", "n").Where( query.EQF("UserID", "`u`.`UserID`"), query.And(), query.EQ("UserGroupID", groupID), query.And(), query.EQ("IsDeleted", 0), ),.
No description provided by the author
Exists is a where clause for the SQL EXISTS statement.
GT is a greater than statement between a table column and a value.
GTOE is a greater than or equals statement (>=) between a table column and a value `t`.`Col` >= value.
IN is an IN clause Example: query.IN("col1", "foo", "bar", "baz").
INInt is a helper function for converting a slice of string arguments into a slice of interface arguments, passed into an IN clause and returned.
INInt64 is a helper function for converting a slice of string arguments into a slice of interface arguments, passed into an IN clause and returned.
No description provided by the author
INString is a helper function for converting a slice of string arguments into a slice of interface arguments, passed into an IN clause and returned.
No description provided by the author
LT is a less than statement between a table column and a value.
LTOE is a less than or equals (<=) statement between a table column and a value `t`.`Col` <= value.
Mod is applies modulo operation on column and value testing if it equals remainder MOD(`t`.`Field`, value) = remainder.
Modf MOD(value, `t`.`Field`) = remainder Example: query.Mod("foo", 2, 1) -> `t`.`Foo` % 2 = 1.
NE is a not equals statement between a table column and a value.
NewField creates a new field.
NewRawField creates a new field.
Exists is a where clause for the SQL EXISTS statement.
NOTIN is an NOT IN clause Example: query.NOTIN("col1", "foo", "bar", "baz") Example: queyr.NOTIN("col2", 1, 2, 3).
No description provided by the author
No description provided by the author
No description provided by the author
Ors takes a list of args and separes them all by `OR` Example: Ors(query.EQ(1,1), query.EQ(2,2), query.EQ(3,3)) == 1 = 1 OR 2 = 2 OR 3 = 3.
No description provided by the author
Parenthesis End.
Parenthesis Start.
No description provided by the author
No description provided by the author
Rawf is a raw SQL statement Example: query.Rawf("`t`.`LastRunDate` + 60000 < %d", seconds)),.
No description provided by the author
No description provided by the author
No description provided by the author
WhereAll adds a WHERE clause of `1=1` used for convenience when conditionally adding WHERE clauses starting with a conjunction (AND/OR,etc) separating them.

# Constants

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
WhereTypeAll is a WHERE clause of `1=1` used for convenience when conditionally adding WHERE clauses starting with a conjunction (AND/OR,etc) separating them.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
WhereTypeNone indicates that the wherePart is a noop for the query, If, however, it contains any child clauses, they will be parsed as individual wherePart objects.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Structs

No description provided by the author
No description provided by the author
WherePart is a part of a where clause.

# Interfaces

No description provided by the author

# Type aliases

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